diff options
| author | 2024-01-11 19:29:09 +0100 | |
|---|---|---|
| committer | 2024-01-11 19:29:09 +0100 | |
| commit | 4f7a13884e9ab16003765e1b01b272a939b5899a (patch) | |
| tree | 20e7d8c204b110d17981712999ae9dde30c9743e /activitypub.c | |
| parent | Updated RELEASE_NOTES. (diff) | |
| download | snac2-4f7a13884e9ab16003765e1b01b272a939b5899a.tar.gz snac2-4f7a13884e9ab16003765e1b01b272a939b5899a.tar.xz snac2-4f7a13884e9ab16003765e1b01b272a939b5899a.zip | |
Better checking for CC creation in msg_note().
Diffstat (limited to 'activitypub.c')
| -rw-r--r-- | activitypub.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activitypub.c b/activitypub.c index c3013d8..dc492ca 100644 --- a/activitypub.c +++ b/activitypub.c | |||
| @@ -1273,8 +1273,8 @@ xs_dict *msg_note(snac *snac, const xs_str *content, const xs_val *rcpts, | |||
| 1273 | if (xs_type(v) == XSTYPE_DICT) { | 1273 | if (xs_type(v) == XSTYPE_DICT) { |
| 1274 | char *t; | 1274 | char *t; |
| 1275 | 1275 | ||
| 1276 | if ((t = xs_dict_get(v, "type")) != NULL && strcmp(t, "Mention") == 0) { | 1276 | if (!xs_is_null(t = xs_dict_get(v, "type")) && strcmp(t, "Mention") == 0) { |
| 1277 | if ((t = xs_dict_get(v, "href")) != NULL) | 1277 | if (!xs_is_null(t = xs_dict_get(v, "href"))) |
| 1278 | cc = xs_list_append(cc, t); | 1278 | cc = xs_list_append(cc, t); |
| 1279 | } | 1279 | } |
| 1280 | } | 1280 | } |