change List() to Nil in matches