correctly add parentheses to the regex