From 352cba8d86580ac4f525f64f3643fbb70d6583f1 Mon Sep 17 00:00:00 2001 From: marty hiatt Date: Thu, 29 Dec 2022 15:10:27 +1100 Subject: fix update local tl, tl--update, like tl--more --- lisp/mastodon-tl.el | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'lisp/mastodon-tl.el') diff --git a/lisp/mastodon-tl.el b/lisp/mastodon-tl.el index 44d31bf..bf334bd 100644 --- a/lisp/mastodon-tl.el +++ b/lisp/mastodon-tl.el @@ -1429,9 +1429,10 @@ PARAMS is used to send 'local=true' for local timeline." ;; TODO ;; Look into the JSON returned here by Local -(defun mastodon-tl--updated-json (endpoint id) +(defun mastodon-tl--updated-json (endpoint id &optional params) "Return JSON for timeline ENDPOINT since ID." (let* ((args `(("since_id" . ,(mastodon-tl--as-string id)))) + (args (if params (push params args) args)) (url (mastodon-http--api endpoint))) (mastodon-http--get-json url args))) @@ -2800,7 +2801,9 @@ from the start if it is nil." (let* ((endpoint (mastodon-tl--get-endpoint)) (update-function (mastodon-tl--get-update-function)) (id (mastodon-tl--newest-id)) - (json (mastodon-tl--updated-json endpoint id))) + (params (when (string= (mastodon-tl--buffer-name) "*mastodon-local*") + '("local" . "true"))) + (json (mastodon-tl--updated-json endpoint id params))) (if json (let ((inhibit-read-only t)) (mastodon-tl--set-after-update-marker) -- cgit v1.2.3