replacing NotCondition with lambda