diff options
author | mousebot <mousebot@riseup.net> | 2022-02-12 11:37:07 +0100 |
---|---|---|
committer | mousebot <mousebot@riseup.net> | 2022-02-12 13:29:15 +0100 |
commit | 0b48cd4b41009d229c3f626e365d670c93ff662c (patch) | |
tree | 65907f7e97380cc6d125a9bee20c8a4ef86656d9 | |
parent | 581cfb870d85324b63e8edaf17a90c0b5c6a9b63 (diff) |
use tl--field to get media attachments info
-rw-r--r-- | lisp/mastodon-tl.el | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lisp/mastodon-tl.el b/lisp/mastodon-tl.el index 66b8baa..c1b0b51 100644 --- a/lisp/mastodon-tl.el +++ b/lisp/mastodon-tl.el @@ -351,12 +351,10 @@ image media from the byline." (defun mastodon-tl--get-media-types (toot) "Return a list of the media attachment types of the TOOT at point." - (let* ((attachments (or (alist-get 'media_attachments - (alist-get 'reblog toot)) - (alist-get 'media_attachments toot)))) + (let* ((attachments (mastodon-tl--field 'media_attachments toot))) (mapcar (lambda (x) (alist-get 'type x)) - medias))) + attachments))) (defun mastodon-tl--get-attachments-for-byline (toot) "Return a list of attachment URLs and types for TOOT. |