closing all instances before runing app