Remove regex match

Remove regex in favor of a safer (`function $foo() {...}`), [faster](http://jsperf.com/regexp-vs-indexof/85) solution.