Convert Regex to work with Ruby 1.8