Fixing bug in utils_match