before changing controllers