refactor find_matches

everything is working as far as i can tell