add a check of two variables