replace if !condition with unless condition

It is better to write "unless condition" instead of "if !condition".