ios - MagicalRecord 2.3.2 MR_saveToPersistentStoreWithCompletion not updating right away -
i using (magicalrecord, 2.3.2). cannot figure out why using mr_savetopersistentstorewithcompletion on mr_defaultcontext gives me "updating fail!" , therefore cannot update entry right away.
[[nsmanagedobjectcontext mr_defaultcontext] mr_savetopersistentstorewithcompletion:^(bool success, nserror *error){ if (success){ nslog(@"updating success!"); } else{ nslog(@"updating fail!"); }}];
mr_savewithoptions:completion: being called mr_savetopersistentstorewithcompletion: , bool haschanges no.
when checked thread call stack in, issue in case, thread nil: {number = 14, name = (null)}
so set main thread , fixed update.
Comments
Post a Comment