Fix issue in which patterns could become too general