mirror of
https://codeberg.org/grunfink/snac2.git
synced 2024-11-09 19:50:26 +03:00
add mastodon profile header to mastodon api
This commit is contained in:
parent
f1294bd3d4
commit
564b5b1161
10
mastoapi.c
10
mastoapi.c
@ -540,6 +540,16 @@ xs_dict *mastoapi_account(const xs_dict *actor)
|
|||||||
avatar = xs_fmt("%s/susie.png", srv_baseurl);
|
avatar = xs_fmt("%s/susie.png", srv_baseurl);
|
||||||
|
|
||||||
acct = xs_dict_append(acct, "avatar", avatar);
|
acct = xs_dict_append(acct, "avatar", avatar);
|
||||||
|
acct = xs_dict_append(acct, "avatar_static", avatar);
|
||||||
|
|
||||||
|
xs *header = NULL;
|
||||||
|
xs_dict *hd = xs_dict_get(actor, "image");
|
||||||
|
|
||||||
|
if (xs_type(hd) == XSTYPE_DICT)
|
||||||
|
header = xs_dup(xs_dict_get(hd, "url"));
|
||||||
|
|
||||||
|
acct = xs_dict_append(acct, "header", header);
|
||||||
|
acct = xs_dict_append(acct, "header_static", header);
|
||||||
|
|
||||||
/* emojis */
|
/* emojis */
|
||||||
xs_list *p;
|
xs_list *p;
|
||||||
|
Loading…
Reference in New Issue
Block a user