Fix pattern matching.