Fix admin interface crashing when listing boosts with non-video media attachments (#12907)

Fix regression introduced by #12879
remotes/1727458204337373841/tmp_refs/heads/signup-info-prompt
ThibG 2020-01-20 17:39:14 +01:00 committed by Eugen Rochko
parent ba16d4b413
commit 91e4955e08
1 changed files with 1 additions and 1 deletions

View File

@ -15,7 +15,7 @@
- if status.proper.media_attachments.first.video? - if status.proper.media_attachments.first.video?
- video = status.proper.media_attachments.first - video = status.proper.media_attachments.first
= react_component :video, src: video.file.url(:original), preview: video.file.url(:small), blurhash: video.blurhash, sensitive: status.proper.sensitive?, visible: false, width: 610, height: 343, inline: true, alt: video.description = react_component :video, src: video.file.url(:original), preview: video.file.url(:small), blurhash: video.blurhash, sensitive: status.proper.sensitive?, visible: false, width: 610, height: 343, inline: true, alt: video.description
- elsif status.media_attachments.first.audio? - elsif status.proper.media_attachments.first.audio?
- audio = status.proper.media_attachments.first - audio = status.proper.media_attachments.first
= react_component :audio, src: audio.file.url(:original), height: 110, alt: audio.description, duration: audio.file.meta.dig(:original, :duration) = react_component :audio, src: audio.file.url(:original), height: 110, alt: audio.description, duration: audio.file.meta.dig(:original, :duration)
- else - else