Fixed bug in Regex