commit e233f3f
violette
·
2025-12-19 08:54:50 +0000 UTC
parent aefdd01
Some fixes.
2 files changed,
+6,
-5
M
html.c
M
html.c
+5,
-4
1@@ -2500,11 +2500,12 @@ xs_html *html_entry(snac *user, xs_dict *msg, int read_only,
2 shortname = xs_dict_get(m, "content");
3
4 const xs_list *items = xs_dict_get(sfrl, content);
5- const char *nb = xs_list_get(items, 0);
6- const xs_list *actors = xs_list_get(items, 1);
7- const char me = *xs_list_get(items, 2) == '1';
8
9- if (!xs_is_null(nb)) {
10+ if (!xs_is_null(items)) {
11+ const char *nb = xs_list_get(items, 0);
12+ const xs_list *actors = xs_list_get(items, 1);
13+ const char me = *xs_list_get(items, 2) == '1';
14+
15 is_emoji = 1;
16
17 xs *al = xs_join(actors, ",\n\t");
+1,
-1
1@@ -1174,7 +1174,7 @@ xs_dict *mastoapi_status(snac *snac, const xs_dict *msg)
2 /* NOTE: idk when there are no actor, but i encountered that bug.
3 * Probably because of one of my previous attempts.
4 * Keeping this just in case, can remove later */
5- const char *me = actor && strcmp(actor, snac->actor) == 0 ?
6+ const char *me = actor && snac && strcmp(actor, snac->actor) == 0 ?
7 xs_stock(XSTYPE_TRUE) : xs_stock(XSTYPE_FALSE);
8 int count = 1;
9