Clears non-main thread cached NSManagedObjectContexts on cleanup. Fixes #335.