| 4771 | |
| 4772 | // noop |
| 4773 | function validateTypeDef(Constructor, typeDef, location) { |
| 4774 | for (var propName in typeDef) { |
| 4775 | if (typeDef.hasOwnProperty(propName)) { |
| 4776 | // use a warning instead of an invariant so components |
| 4777 | // don't show up in prod but only in __DEV__ |
| 4778 | "development" !== 'production' ? warning(typeof typeDef[propName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', Constructor.displayName || 'ReactClass', ReactPropTypeLocationNames[location], propName) : void 0; |
| 4779 | } |
| 4780 | } |
| 4781 | } |
| 4782 | |
| 4783 | function validateMethodOverride(isAlreadyDefined, name) { |
| 4784 | var specPolicy = ReactClassInterface.hasOwnProperty(name) ? ReactClassInterface[name] : null; |