Some changes in regex pattern