commit 52d54ed

grunfink  ·  2023-06-11 16:58:54 +0000 UTC
parents f6b836e, 9b1c5cc
Merge pull request 'set bot to true for bots in mastodon api' (#45) from Haijo7/snac2:masto-api-user-type into master

Reviewed-on: https://codeberg.org/grunfink/snac2/pulls/45
1 files changed,  +5, -0
+5, -0
 1@@ -522,6 +522,11 @@ xs_dict *mastoapi_account(const xs_dict *actor)
 2     if (xs_is_null(note))
 3         note = "";
 4 
 5+    if (strcmp(xs_dict_get(actor, "type"), "Service") == 0)
 6+        acct = xs_dict_append(acct, "bot", "true");
 7+    else
 8+        acct = xs_dict_append(acct, "bot", "false");
 9+
10     acct = xs_dict_append(acct, "note", note);
11 
12     acct = xs_dict_append(acct, "url", id);