Skip to content

Commit

Permalink
remove TypeError
Browse files Browse the repository at this point in the history
  • Loading branch information
tanmoyopenroot committed Sep 17, 2019
1 parent f0bd716 commit 775909a
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions lib/rules/jsx-handler-names.js
Expand Up @@ -68,10 +68,6 @@ module.exports = {
null :
configuration.eventHandlerPropPrefix || 'on';

if (!eventHandlerPrefix && !eventHandlerPropPrefix) {
throw new TypeError('Both \'eventHandlerPrefix\' and \'eventHandlerPropPrefix\' cannot be false');
}

const EVENT_HANDLER_REGEX = !eventHandlerPrefix ?
null :
new RegExp(`^((props\\.${eventHandlerPropPrefix || ''})|((.*\\.)?${eventHandlerPrefix}))[A-Z].*$`);
Expand Down

0 comments on commit 775909a

Please sign in to comment.