Closed rocksoftcode closed 7 years ago
Sending a fat arrow function without parens (one arg only) into brakes causes an exception: TypeError: Cannot read property '1' of null
TypeError: Cannot read property '1' of null
It appears to be breaking on the regex in getFnArgs in lib/utils.js:
getFnArgs
lib/utils.js
/^[function\s]?.*?\(([^)]*)\)/
Here's a PR for a potential fix: https://github.com/awolden/brakes/pull/84
Thanks for the contribution @rockympls!
Sending a fat arrow function without parens (one arg only) into brakes causes an exception:
TypeError: Cannot read property '1' of null
It appears to be breaking on the regex in
getFnArgs
inlib/utils.js
: