Replaced regex with indexOf
http://jsperf.com/dot-indexof-vs-regex