Abstract out resetting the background