summaryrefslogtreecommitdiff
path: root/mastoapi.c
diff options
context:
space:
mode:
Diffstat (limited to 'mastoapi.c')
-rw-r--r--mastoapi.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/mastoapi.c b/mastoapi.c
index e52f86b..06ec915 100644
--- a/mastoapi.c
+++ b/mastoapi.c
@@ -456,7 +456,12 @@ xs_dict *mastoapi_account(const xs_dict *actor)
acct = xs_dict_append(acct, "created_at", date);
}
- acct = xs_dict_append(acct, "note", xs_dict_get(actor, "summary"));
+ const char *note = xs_dict_get(actor, "summary");
+ if (xs_is_null(note))
+ note = "";
+
+ acct = xs_dict_append(acct, "note", note);
+
acct = xs_dict_append(acct, "url", id);
xs *avatar = NULL;