             }
         }
     }
-
+    
     func applicationWillResignActive(application: UIApplication) {
         // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
         // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
-        print("applicationWillResignActive") //ignore  
+        print("applicationWillResignActive") //ignore
         print(application)
     }
-
+    
     func applicationDidEnterBackground(application: UIApplication) {
         /*
          Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.

    func firstTime() {
        // Set up a user entering for the first time
        // if true it will prompt a pscope
        // 
        // if denied access users can change permissions later
        // display root controller otherwise
        let first_time = KeychainSwift().getBool("firstTime")

            let tabIndex: Int = tabBarController.selectedIndex
            let userDefaults: NSUserDefaults = NSUserDefaults.standardUserDefaults()
            userDefaults.setInteger(tabIndex, forKey: "activeTab")
            
            if !userDefaults.synchronize() {
                print("Error Synchronizing NSUserDefaults")
            }
