1
0
mirror of https://github.com/ascribe/onion.git synced 2024-11-15 09:35:10 +01:00

Define more strict props & re-change method name to componentWillUpdate again

This commit is contained in:
Tim Daubenschütz 2015-11-16 15:15:55 +01:00
parent cb6e94c8f1
commit dd8fe34bb6

View File

@ -113,7 +113,7 @@ let ReactS3FineUploader = React.createClass({
// 'hash': upload using the hash // 'hash': upload using the hash
// 'upload': upload full file (default if not specified) // 'upload': upload full file (default if not specified)
enableLocalHashing: React.PropTypes.bool, enableLocalHashing: React.PropTypes.bool,
uploadMethod: React.PropTypes.string, uploadMethod: React.PropTypes.oneOf(['hash', 'upload']),
// A class of a file the user has to upload // A class of a file the user has to upload
// Needs to be defined both in singular as well as in plural // Needs to be defined both in singular as well as in plural
@ -202,7 +202,7 @@ let ReactS3FineUploader = React.createClass({
}; };
}, },
componentWillReceiveProps() { componentWillUpdate() {
// since the csrf header is defined in this component's props, // since the csrf header is defined in this component's props,
// everytime the csrf cookie is changed we'll need to reinitalize // everytime the csrf cookie is changed we'll need to reinitalize
// fineuploader and update the actual csrf token // fineuploader and update the actual csrf token