progress bar decreases slowly on exit instead of resetting