move the config out of the destroy check