I have a navigation based app. The screen List has a UITableView
with a list of books. The list of books is in a property NSArray
that was built dynamically by executing an HTTP request. When one clicks in one of the rows in the List, one'll navigate to the screen Details. Let's say there is a memory warning at this point. When you come back to the screen List, the NSArray
is nil because viewDidUnload
was called, so the List will be empty.
What is the correct way to handle this situation? Should I not set the NSArray
to nil in viewDidUnload
?