diff options
author | Reverite <github@reverite.sh> | 2019-10-05 12:13:22 -0700 |
---|---|---|
committer | Reverite <github@reverite.sh> | 2019-10-05 12:13:22 -0700 |
commit | 46ada47e09af0da9c776ef83c0ff034c720a83d6 (patch) | |
tree | 54fd4b1d5fba6d592f328955ef5968608bbe716f /app/javascript/flavours/glitch/features/account_gallery/index.js | |
parent | 333b5e25f0a615a9518d402ef10dceb70190a52f (diff) | |
parent | 3921125e5578fb3871fdcae0e8e8a77179f1ad72 (diff) |
Merge branch 'glitch' into production
Diffstat (limited to 'app/javascript/flavours/glitch/features/account_gallery/index.js')
-rw-r--r-- | app/javascript/flavours/glitch/features/account_gallery/index.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/javascript/flavours/glitch/features/account_gallery/index.js b/app/javascript/flavours/glitch/features/account_gallery/index.js index 597196567..ff39764bb 100644 --- a/app/javascript/flavours/glitch/features/account_gallery/index.js +++ b/app/javascript/flavours/glitch/features/account_gallery/index.js @@ -111,8 +111,10 @@ class AccountGallery extends ImmutablePureComponent { } handleOpenMedia = attachment => { - if (['video', 'audio'].includes(attachment.get('type'))) { + if (attachment.get('type') === 'video') { this.props.dispatch(openModal('VIDEO', { media: attachment, status: attachment.get('status') })); + } else if (attachment.get('type') === 'audio') { + this.props.dispatch(openModal('AUDIO', { media: attachment, status: attachment.get('status') })); } else { const media = attachment.getIn(['status', 'media_attachments']); const index = media.findIndex(x => x.get('id') === attachment.get('id')); |