remove fnmatch with custom match