Correcting parse into if block