Web: Components: fixed error log after closing profile

This commit is contained in:
Nikita Gopienko 2022-04-26 14:34:04 +03:00
parent 68970eeebd
commit 4917c3e9ff

View File

@ -81,8 +81,10 @@ class AvatarEditor extends React.Component {
};
onClose = () => {
this.setState({ visible: false });
this.props.onClose();
if (this.state.visible) {
this.setState({ visible: false });
this.props.onClose();
}
};
componentDidUpdate(prevProps) {