I am trying to introduce ODR in my application and facing the following crash.
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'beginAccessingResources was called more than once or at the wrong time (3)'
This is what I have done so far.
- Created two asset packs with Tags Bell1 and Bell2.
- Requesting for Bell1 tag on appDidFinishLauching after calling conditionallyBeginAccessingResourcesWithCompletionHandler.
- Requesting for Bell2 on the viewDidLoad of the Home controller after the login is done.
(Just FYI: I am not calling endAccessingResources anywhere for the time being.)
If I remove the step 3 or request both resources in a single request then the app works fine. If I create two simultenous NSBundleResourceRequest then the app is crashing.
So far I have searched stackoverflow and read the documentation but couldn't find any help regarding this issue.