Check bool instead of int in IF