aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarty hiatt <martianhiatus [a t] riseup [d o t] net>2022-06-27 18:13:59 +0200
committermarty hiatt <martianhiatus [a t] riseup [d o t] net>2022-06-27 18:13:59 +0200
commit8774ec32e36a9c12c9b772211009be12249b3efc (patch)
treec17d7e73b0186c50571857d5a47a892e7ccad3a8
parent4ab5a4bb8d603b189a99cc4a4eea4c42e8f97cf0 (diff)
--get-buffer-property: or rather than if
-rw-r--r--lisp/mastodon-tl.el7
1 files changed, 3 insertions, 4 deletions
diff --git a/lisp/mastodon-tl.el b/lisp/mastodon-tl.el
index 05eaa63..9b91e1c 100644
--- a/lisp/mastodon-tl.el
+++ b/lisp/mastodon-tl.el
@@ -1036,10 +1036,9 @@ Optionally get it for BUFFER."
(defun mastodon-tl--get-buffer-property (property &optional buffer)
"Get PROPERTY from `mastodon-tl--buffer-spec' in BUFFER or `current-buffer'."
(with-current-buffer (or buffer (current-buffer))
- (if (plist-get mastodon-tl--buffer-spec property)
- (plist-get mastodon-tl--buffer-spec property)
- (error "Mastodon-tl--buffer-spec is not defined for buffer %s"
- (or buffer (current-buffer))))))
+ (or (plist-get mastodon-tl--buffer-spec property)
+ (error "Mastodon-tl--buffer-spec is not defined for buffer %s"
+ (or buffer (current-buffer))))))
(defun mastodon-tl--more-json (endpoint id)
"Return JSON for timeline ENDPOINT before ID."