Fixed pattern matching error