fix the ApBar reset bug