1
0
Fork 0
mirror of https://github.com/mastodon/mastodon.git synced 2024-08-20 21:08:15 -07:00
This commit is contained in:
Tiago Peralta 2024-07-31 11:04:47 +00:00 committed by GitHub
commit 1764dec34a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -287,7 +287,9 @@ class MediaGallery extends PureComponent {
isFullSizeEligible() { isFullSizeEligible() {
const { media } = this.props; const { media } = this.props;
return media.size === 1 && media.getIn([0, 'meta', 'small', 'aspect']); const aspect = media.getIn([0, 'meta', 'small', 'aspect']);
const minAspectRatioThreshold = 3/2;
return media.size === 1 && typeof aspect === 'number' && aspect >= minAspectRatioThreshold;
} }
render () { render () {