mirror of
https://github.com/element-hq/element-web
synced 2024-10-24 19:55:54 +03:00
Fix bug that would cause failed to decrypt messages in non-encrypted rooms
This commit is contained in:
parent
d10234740b
commit
c8485419c1
1 changed files with 3 additions and 3 deletions
|
@ -143,9 +143,8 @@ export default class MVideoBody extends React.PureComponent<IProps, IState> {
|
||||||
}
|
}
|
||||||
|
|
||||||
async _videoOnPlay() {
|
async _videoOnPlay() {
|
||||||
const autoplay = SettingsStore.getValue("autoplayGifsAndVideos") as boolean;
|
if (this._getContentUrl() || this.state.fetchingData || this.state.error) {
|
||||||
if (autoplay || this.state.decryptedUrl || this.state.fetchingData || this.state.error) {
|
// We have the file, we are fetching the file, or there is an error.
|
||||||
// The video has or will have the data.
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this.setState({
|
this.setState({
|
||||||
|
@ -164,6 +163,7 @@ export default class MVideoBody extends React.PureComponent<IProps, IState> {
|
||||||
this.setState({
|
this.setState({
|
||||||
decryptedUrl: contentUrl,
|
decryptedUrl: contentUrl,
|
||||||
decryptedBlob: decryptedBlob,
|
decryptedBlob: decryptedBlob,
|
||||||
|
fetchingData: false,
|
||||||
});
|
});
|
||||||
this.props.onHeightChanged();
|
this.props.onHeightChanged();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue