From fb1d9789dba288599e05ba813af0c61f484e205c Mon Sep 17 00:00:00 2001 From: Claire Date: Thu, 15 Dec 2022 17:41:20 +0100 Subject: [PATCH] Fix attachment rendering of edited posts in OpenGraph (#22270) Fixes #22241 --- app/helpers/statuses_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/statuses_helper.rb b/app/helpers/statuses_helper.rb index 488eabeec..d1e3fddaf 100644 --- a/app/helpers/statuses_helper.rb +++ b/app/helpers/statuses_helper.rb @@ -21,7 +21,7 @@ module StatusesHelper def media_summary(status) attachments = { image: 0, video: 0, audio: 0 } - status.media_attachments.each do |media| + status.ordered_media_attachments.each do |media| if media.video? attachments[:video] += 1 elsif media.audio?