Reduced the RegEx code