fix some update bugs