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

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

[nongnu] elpa/mastodon ca0b443a79 13/52: fix init-sync for notifs-get co


From: ELPA Syncer
Subject: [nongnu] elpa/mastodon ca0b443a79 13/52: fix init-sync for notifs-get compat with link-header/get-response
Date: Mon, 30 Oct 2023 16:01:24 -0400 (EDT)

branch: elpa/mastodon
commit ca0b443a79bfe54b77bd7ffebbc0e1f361c2d783
Author: marty hiatt <martianhiatus [a t] riseup [d o t] net>
Commit: marty hiatt <martianhiatus [a t] riseup [d o t] net>

    fix init-sync for notifs-get compat with link-header/get-response
---
 lisp/mastodon-tl.el | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/lisp/mastodon-tl.el b/lisp/mastodon-tl.el
index d5d127db52..67ceb9e991 100644
--- a/lisp/mastodon-tl.el
+++ b/lisp/mastodon-tl.el
@@ -2672,11 +2672,13 @@ Optional arg NOTE-TYPE means only get that type of 
note."
          (url (mastodon-http--api endpoint))
          (buffer (concat "*mastodon-" buffer-name "*"))
          (response (mastodon-http--get-response url params))
-         (json (if headers (car response) response))
-         (headers (if headers (cdr response) nil))
-         (link-header (mastodon-tl--get-link-header-from-response headers)))
+         (json (car response))
+         (headers (when headers (cdr response)))
+         (link-header (when headers
+                        (mastodon-tl--get-link-header-from-response headers))))
     (with-mastodon-buffer buffer #'mastodon-mode nil
-      (mastodon-tl--set-buffer-spec buffer endpoint update-function 
link-header params)
+      (mastodon-tl--set-buffer-spec buffer endpoint update-function
+                                    link-header params)
       (mastodon-tl--do-init json update-function)
       buffer)))
 



reply via email to

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