Remove unneccesary nested else if