Refactor custom matcher to make more sense