Pattern match fix