dariusk/wordfilter — pull request #10 by puckey (2014-11-19 12:44:02+00:00)
Title: Use a single regular expression instead of a for loop.

I think using a single regular expression test instead of checking each word individually makes sense.. The regular expression only compiled once and for each change of the word list (which should be only once).

I also added tests for partial word matches and use require to load the badwords list (the json of which I also simplified).