aboutsummaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authormarty hiatt <martianhiatus@riseup.net>2024-06-01 11:00:44 +0200
committermarty hiatt <martianhiatus@riseup.net>2024-06-01 11:05:09 +0200
commit9239f652265e0a3f29f73c442a1b2d3d0b3e5c16 (patch)
tree9a27ab22f312babf6b42859423bfff153b4d67f7 /lisp
parent13162773b6fcff121bf3449075201a49547f68c4 (diff)
set max-id in buffer spec also after reloading
Diffstat (limited to 'lisp')
-rw-r--r--lisp/mastodon-tl.el8
1 files changed, 6 insertions, 2 deletions
diff --git a/lisp/mastodon-tl.el b/lisp/mastodon-tl.el
index fe8f9f1..28177bc 100644
--- a/lisp/mastodon-tl.el
+++ b/lisp/mastodon-tl.el
@@ -2932,7 +2932,9 @@ JSON and http headers, without it just the JSON."
(link-header (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 update-params hide-replies)
+ link-header update-params hide-replies
+ ;; awful hack to fix multiple reloads:
+ (alist-get "max_id" update-params nil nil #'equal))
(mastodon-tl--do-init json update-function instance)))))))
(defun mastodon-tl--init-sync
@@ -2968,7 +2970,9 @@ BINDING-STR is a string explaining any bindins in the view."
(insert (mastodon-tl--set-face (concat "[" binding-str "]\n\n")
'font-lock-comment-face)))
(mastodon-tl--set-buffer-spec buffer endpoint update-function
- link-header params)
+ link-header params nil
+ ;; awful hack to fix multiple reloads:
+ (alist-get "max_id" params nil nil #'equal))
(mastodon-tl--do-init json update-function)
buffer)))