Explorar o código

add user type to mastodon profile

Haijo7 %!s(int64=3) %!d(string=hai) anos
pai
achega
2544ec92b2
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      mastoapi.c

+ 2 - 0
mastoapi.c

@@ -497,9 +497,11 @@ xs_dict *mastoapi_account(const xs_dict *actor)
         display_name = prefu;
         display_name = prefu;
 
 
     const char *id  = xs_dict_get(actor, "id");
     const char *id  = xs_dict_get(actor, "id");
+    const char *type  = xs_dict_get(actor, "type");
     const char *pub = xs_dict_get(actor, "published");
     const char *pub = xs_dict_get(actor, "published");
     xs *acct_md5 = xs_md5_hex(id, strlen(id));
     xs *acct_md5 = xs_md5_hex(id, strlen(id));
     acct = xs_dict_append(acct, "id",           acct_md5);
     acct = xs_dict_append(acct, "id",           acct_md5);
+    acct = xs_dict_append(acct, "type",         type);
     acct = xs_dict_append(acct, "username",     prefu);
     acct = xs_dict_append(acct, "username",     prefu);
     acct = xs_dict_append(acct, "display_name", display_name);
     acct = xs_dict_append(acct, "display_name", display_name);