Fix typo in if caluse

Fixes #729