commit 2416945
default
·
2024-11-17 09:23:43 +0000 UTC
parent ec5ba68
In the insert cmdline op, don't re-add if it's already in the timeline.
1 files changed,
+5,
-1
M
main.c
M
main.c
+5,
-1
1@@ -558,7 +558,11 @@ int main(int argc, char *argv[])
2 if (data != NULL) {
3 xs_json_dump(data, 4, stdout);
4 enqueue_actor_refresh(&snac, xs_dict_get(data, "attributedTo"), 0);
5- timeline_add(&snac, url, data);
6+
7+ if (!timeline_here(&snac, url))
8+ timeline_add(&snac, url, data);
9+ else
10+ printf("Post %s already here\n", url);
11 }
12
13 return 0;