ReferenceError: tokens is not defined
Closed this issue · 4 comments
When passing an Array that contains a string with a trailing _
character through validForms
, an error is thrown within _forms
: tokens is not defined
In reviewing the code, it looks like a simple typo: token vs. tokens (the two are used interchangeably in this function, but only token is declared). It would seem the split occurring would have its result assigned to tokens instead of token, but I'd need a bit more context to fix this completely + run the test suite locally. I can do that if this isn't a clear-cut fix for you @morungos. Let me know if I can help!
Good catch and a clear bug.
Great, thanks for the fast response! (that was an accidental Issue close)
Pushed a new version 0.1.9 to npm, and all should be well now. There was a bit more wrong than I'd expected, so a few new tests are added too.
👍