fixed app creation and deletion