some updates to if