Created matchName function