mirror of
https://github.com/ascribe/onion.git
synced 2024-12-22 17:33:14 +01:00
Check for a new csrf token on componentWillReceiveProps instead of componentWillUpdate
this.setState() should not be used in componentWillUpdate(): https://facebook.github.io/react/docs/component-specs.html#updating-comp onentwillupdate
This commit is contained in:
parent
5f5461c10d
commit
49f20462f1
@ -202,7 +202,7 @@ let ReactS3FineUploader = React.createClass({
|
||||
};
|
||||
},
|
||||
|
||||
componentWillUpdate() {
|
||||
componentWillReceiveProps() {
|
||||
// since the csrf header is defined in this component's props,
|
||||
// everytime the csrf cookie is changed we'll need to reinitalize
|
||||
// fineuploader and update the actual csrf token
|
||||
|
Loading…
Reference in New Issue
Block a user