Created
January 9, 2020 09:04
-
-
Save MickaelCruzDB/2bb879e9a832345d29a40988ce69ab24 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { | |
// Override point for customization after application launch. | |
let appDelegate = UIApplication.shared.delegate as! AppDelegate | |
let context = appDelegate.persistentContainer.viewContext | |
let request = NSFetchRequest<NSFetchRequestResult>(entityName: "AppVersion") | |
request.returnsObjectsAsFaults = false | |
do { | |
let result = try context.fetch(request) | |
for data in result as! [NSManagedObject] { | |
print("-----> \(data.value(forKey: "proLogged") as! String)") | |
} | |
} catch { | |
print("Failed") | |
} | |
return true | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment