diff --git a/src/components/views/elements/ToggleSwitch.js b/src/components/views/elements/ToggleSwitch.js index 19c87aab56d..0d8b3d042ff 100644 --- a/src/components/views/elements/ToggleSwitch.js +++ b/src/components/views/elements/ToggleSwitch.js @@ -38,6 +38,12 @@ export default class ToggleSwitch extends React.Component { }; } + componentWillReceiveProps(nextProps) { + if (nextProps.checked !== this.state.checked) { + this.setState({checked: nextProps.checked}); + } + } + _onClick = (e) => { e.stopPropagation(); e.preventDefault();