Rethinking match? function to make larger process more efficient.