Substitute `match` method for the `=~` operator

The `match` method generates a MatchData object, making it slower than
`=~` [1]. Since this object is not being used, it makes sense to switch
to `=~`.

[1]: http://stackoverflow.com/a/11908214/1160916
Fix whitespace