Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Suggested changes #204

Closed
wants to merge 6 commits into
from
Commits on Jul 9, 2012
  1. Existing methods did not provide an easy way to create a background s…

    ChronicStim committed Jul 9, 2012
    …ave operation in a context that was not a child of the MR_defaultContext. So, this new method takes any parent context as an input and then creates a child context on which to perform the background save.
  2. Change the && to || so that if the receiver is not the default or roo…

    ChronicStim committed Jul 9, 2012
    …tSaving contexts, the completion handler will still be run.
    
    Also added a return; on the initial IF statement so that the completion handler does not get run twice as would be the case if the context was the MR_defaultContext.
  3. Performing operations on objects within nested contexts where the MR_…

    ChronicStim committed Jul 9, 2012
    …inContext: method was used was throwing errors when objects with tempID's were being passed to the method. The solution was to check if the ID is temporary and then if it is, request a permanentID before continuing.
  4. Adding an easy to understand identification string to contexts throug…

    ChronicStim committed Jul 9, 2012
    …h the userInfo property on the context. This is then referenced when using the MR_description method or can be used independently in your own MRLog debug comments. Quite helpful when you're dealing with multiple nested contexts. For example, I might name a context "DiaryEntryEditingContext" or "DiaryEntryDeletionContext" using these methods.
    
    The MR_description method was also updated to show a recursive "family tree" of the contexts by looking for the parentContext, then the parent of the parent, etc. and listing them in the string.
Commits on Jul 13, 2012
  1. Switched background save method's action from performBlockAndWait bac…

    ChronicStim committed Jul 13, 2012
    …k to performBlock to try and reduce blocking the main thread. This was giving problems early in the integration of MR, but it seems to be working fine now, so I believe it should be defined this way.