match() -> test()

Replace `match()` with `test()` as result is used as a Boolean.