I'm trying to access my core data from the watch kit extension but i'm unable to use the shared application because it's not available in watch kit. How do I initialize the
managedObjectContext
within my view controller without using the shared application code?if (self.managedObjectContext_ == nil) { self.managedObjectContext_ = [(AppDelegate *)[[UIApplication sharedApplication] delegate] managedObjectContext]; }
right now, it's assuming my
managedObjectContext
is nil.How do I initialize core data outside my app delegate in the watchkit controllers?