aboutsummaryrefslogtreecommitdiff
path: root/lisp/mastodon-tl.el
diff options
context:
space:
mode:
authormarty hiatt <martianhiatus@riseup.net>2024-06-15 12:44:52 +0200
committermarty hiatt <martianhiatus@riseup.net>2024-06-15 12:44:52 +0200
commit901da7f72221be31109cd4c47a31fe4314c6a6f2 (patch)
treeeb9b665ea0060aa938f536b91b08067b5b072706 /lisp/mastodon-tl.el
parent09212d2a6db0b3604014e4371f3b0c92376bc6e0 (diff)
with-mastodon-buffer : switch buffer after body
Diffstat (limited to 'lisp/mastodon-tl.el')
-rw-r--r--lisp/mastodon-tl.el5
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/mastodon-tl.el b/lisp/mastodon-tl.el
index c330dbd..3611d1c 100644
--- a/lisp/mastodon-tl.el
+++ b/lisp/mastodon-tl.el
@@ -325,10 +325,11 @@ than `pop-to-buffer'."
(erase-buffer)
(funcall ,mode-fun)
(remove-overlays) ; video overlays
+ ,@body
+ ;; return result of switching buffer:
(if ,other-window
(switch-to-buffer-other-window ,buffer)
- (pop-to-buffer ,buffer '(display-buffer-same-window)))
- ,@body)))
+ (pop-to-buffer ,buffer '(display-buffer-same-window))))))
(defmacro mastodon-tl--do-if-item (&rest body)
"Execute BODY if we have an item at point."