reverting to previous state