Fix media modal prev button behavior. (#4158)

signup-info-prompt
Naoki Kosaka 2017-07-12 02:56:45 +09:00 committed by Eugen Rochko
parent 1c6c6b271c
commit b21ab498f8
1 changed files with 1 additions and 1 deletions

View File

@ -35,7 +35,7 @@ export default class MediaModal extends ImmutablePureComponent {
} }
handlePrevClick = () => { handlePrevClick = () => {
this.setState({ index: (this.getIndex() - 1) % this.props.media.size }); this.setState({ index: (this.props.media.size + this.getIndex() - 1) % this.props.media.size });
} }
handleKeyUp = (e) => { handleKeyUp = (e) => {