Skip to content

Commit

Permalink
remove includes in favor of indexOf
Browse files Browse the repository at this point in the history
  • Loading branch information
brad-decker committed Jun 1, 2016
1 parent b032911 commit 635ce80
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/isomorphic/classic/types/checkReactTypeSpec.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ function checkReactTypeSpec(typeSpecs, values, location, componentName, element,
componentStackInfo
);
}
if (mismatched.includes(typeSpecName.toLowerCase())) {
const mismatch = mismatched.find(item => item === typeSpecName.toLowerCase());
if (mismatched.indexOf(typeSpecName.toLowerCase()) !== -1) {
const mismatch = mismatched[mismatched.indexOf(typeSpecName.toLowerCase())];
warning(
false,
'Provided prop %s is not defined in propTypes, did you mean %s?',
Expand Down

0 comments on commit 635ce80

Please sign in to comment.