Fixed bug with regular expression