remove un-needed if