fixed bugs about <if> block