added detetion on wrong rules base on wrong variables