cleaning
cleaning and adapting for safe mode