diff options
| author | 2023-10-13 09:14:11 +0200 | |
|---|---|---|
| committer | 2023-10-13 09:14:11 +0200 | |
| commit | 3385bda618941e7412dc5450f53c5b15dba78217 (patch) | |
| tree | b2ab953d35160eeac0272c32f3ae97522f458376 | |
| parent | Updated RELEASE_NOTES. (diff) | |
| download | snac2-3385bda618941e7412dc5450f53c5b15dba78217.tar.gz snac2-3385bda618941e7412dc5450f53c5b15dba78217.tar.xz snac2-3385bda618941e7412dc5450f53c5b15dba78217.zip | |
Minor URI tweak.
| -rw-r--r-- | mastoapi.c | 9 |
1 files changed, 7 insertions, 2 deletions
| @@ -946,12 +946,17 @@ xs_dict *mastoapi_status(snac *snac, const xs_dict *msg) | |||
| 946 | 946 | ||
| 947 | if (valid_status(object_get_by_md5(boosted_by_md5, &b_actor))) { | 947 | if (valid_status(object_get_by_md5(boosted_by_md5, &b_actor))) { |
| 948 | xs *b_acct = mastoapi_account(b_actor); | 948 | xs *b_acct = mastoapi_account(b_actor); |
| 949 | xs *fake_uri = xs_fmt("%s/d/%s", srv_baseurl, mid); | 949 | xs *fake_uri = NULL; |
| 950 | |||
| 951 | if (snac) | ||
| 952 | fake_uri = xs_fmt("%s/d/%s/Announce", snac->actor, mid); | ||
| 953 | else | ||
| 954 | fake_uri = xs_fmt("%s#%s", srv_baseurl, mid); | ||
| 950 | 955 | ||
| 951 | bst = xs_dict_append(bst, "id", mid); | 956 | bst = xs_dict_append(bst, "id", mid); |
| 952 | bst = xs_dict_append(bst, "created_at", xs_dict_get(st, "created_at")); | 957 | bst = xs_dict_append(bst, "created_at", xs_dict_get(st, "created_at")); |
| 953 | bst = xs_dict_append(bst, "account", b_acct); | ||
| 954 | bst = xs_dict_append(bst, "uri", fake_uri); | 958 | bst = xs_dict_append(bst, "uri", fake_uri); |
| 959 | bst = xs_dict_append(bst, "account", b_acct); | ||
| 955 | bst = xs_dict_append(bst, "content", ""); | 960 | bst = xs_dict_append(bst, "content", ""); |
| 956 | bst = xs_dict_append(bst, "reblog", st); | 961 | bst = xs_dict_append(bst, "reblog", st); |
| 957 | 962 | ||