commit 04ba281
default
·
2023-04-23 12:50:54 +0000 UTC
parent 21fa6c7
Fixed a bug in the instance timeline.
1 files changed,
+3,
-3
+3,
-3
1@@ -913,7 +913,7 @@ int mastoapi_get_handler(const xs_dict *req, const char *q_path,
2 if (strcmp(cmd, "/v1/timelines/public") == 0) {
3 /* the public timeline (public timelines for all users) */
4
5- /* this is a kludge: first users in the list get all the fame */
6+ /* this is an ugly kludge: first users in the list get all the fame */
7
8 const char *limit_s = xs_dict_get(args, "limit");
9 int limit = 0;
10@@ -934,7 +934,7 @@ int mastoapi_get_handler(const xs_dict *req, const char *q_path,
11 snac user;
12
13 if (user_open(&user, uid)) {
14- xs *timeline = timeline_simple_list(&snac1, "public", 0, 4);
15+ xs *timeline = timeline_simple_list(&user, "public", 0, 4);
16 xs_list *p2 = timeline;
17 xs_str *v;
18
19@@ -954,7 +954,7 @@ int mastoapi_get_handler(const xs_dict *req, const char *q_path,
20 continue;
21
22 /* convert the Note into a Mastodon status */
23- xs *st = mastoapi_status(&snac1, msg);
24+ xs *st = mastoapi_status(&user, msg);
25
26 if (st != NULL) {
27 out = xs_list_append(out, st);