From a11ad62be3bd49ca1fea1d32bb98e3772f538f48 Mon Sep 17 00:00:00 2001 From: Masaya Tojo Date: Fri, 10 Jul 2020 05:10:08 +0900 Subject: qkbox: toot: Update status-visibility. --- qkbox/toot.scm | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/qkbox/toot.scm b/qkbox/toot.scm index e35d027..7d42e65 100644 --- a/qkbox/toot.scm +++ b/qkbox/toot.scm @@ -103,7 +103,7 @@ (assoc-ref (status-json status) "content")) (define (status-visibility status) - (assoc-ref (status-json status) "visibility")) + (string->symbol (assoc-ref (status-json status) "visibility"))) (define (status-spoiler-text status) (let ((s (assoc-ref (status-json status) "spoiler_text"))) @@ -152,9 +152,10 @@ (avatar-static->pict (status-avatar-static status)) (status-id status) (status-acct status) - (if (string=? (status-visibility status) "public") - #f - (status-visibility status)) + (case (status-visibility status) + ((public) #f) + (else + (status-visibility status))) (cond ((status-spoiler-text status) => (lambda (spoiler-text) -- cgit v1.2.3