Skip to content
This repository was archived by the owner on Oct 28, 2021. It is now read-only.

Commit 9bce3c4

Browse files
author
Evandro Carenho
committed
fix: Merging fix from Fix-Configurator-Cancel-Loading.
1 parent f00379d commit 9bce3c4

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

components/SubmitInstance/SubmitInstance.jsx

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,14 @@ export class SubmitInstance extends Component {
3838
}
3939

4040
componentWillReceiveProps(nextProps) {
41-
if (this.props.saved !== nextProps.saved) {
42-
if (nextProps.saved) {
43-
if (nextProps.operation === 'CREATE' || nextProps.operation === 'UPDATE') {
44-
hashHistory.push('/instance-created');
45-
} else if (nextProps.operation === 'REMOVE') {
46-
hashHistory.push('/');
47-
}
48-
} else {
41+
if (nextProps.saved) {
42+
if (nextProps.operation === 'CREATE' || nextProps.operation === 'UPDATE') {
43+
hashHistory.push('/instance-created');
44+
} else if (nextProps.operation === 'REMOVE') {
4945
hashHistory.push('/');
5046
}
47+
} else {
48+
hashHistory.push('/');
5149
}
5250
}
5351

0 commit comments

Comments
 (0)