Updated to not use a RegExp object and removed unneeded characters from the regex.