Pattern.Match is obsolete
Removing pattern.match