emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/mastodon 00b1ac63d5 04/18: notifications--render: fallback


From: ELPA Syncer
Subject: [nongnu] elpa/mastodon 00b1ac63d5 04/18: notifications--render: fallback to first id if no status_id. ??
Date: Mon, 2 Dec 2024 16:00:33 -0500 (EST)

branch: elpa/mastodon
commit 00b1ac63d5360c30244a7b4405ceb4f578c65747
Author: marty hiatt <martianhiatus@disroot.org>
Commit: marty hiatt <martianhiatus@disroot.org>

    notifications--render: fallback to first id if no status_id. ??
---
 lisp/mastodon-notifications.el | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/lisp/mastodon-notifications.el b/lisp/mastodon-notifications.el
index 804cc7d2a1..93a3d66204 100644
--- a/lisp/mastodon-notifications.el
+++ b/lisp/mastodon-notifications.el
@@ -476,7 +476,12 @@ NO-GROUP means don't render grouped notifications."
                        (alist-get 'sample_account_ids g)
                        (alist-get 'accounts json))
        for status = (mastodon-notifications--alist-by-value
-                     (alist-get 'status_id g) 'id
+                     (or (alist-get 'status_id g)
+                         ;; if no status_id, just try the first item?
+                         (alist-get 'id
+                                    (car
+                                     (alist-get 'statuses json))))
+                     'id
                      (alist-get 'statuses json))
        do (mastodon-notifications--format-group-note g status accounts)
        (when mastodon-tl--display-media-p



reply via email to

[Prev in Thread] Current Thread [Next in Thread]