modify AppDelegate