Skip to content

Commit d61a096

Browse files
Mark Richmondljharb
Mark Richmond
authored andcommitted
Fix TypeError for undefined node in PropType.shape
1 parent a7bc91b commit d61a096

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/rules/no-typos.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ module.exports = {
7373
}
7474

7575
function checkValidPropObject (node) {
76-
if (node.type === 'ObjectExpression') {
76+
if (node && node.type === 'ObjectExpression') {
7777
node.properties.forEach(prop => checkValidProp(prop.value));
7878
}
7979
}

0 commit comments

Comments
 (0)