Skip to content
RED SAGSkills
hard20 pts · first answer countsswiftmemory-management

unowned self in a network callback

The user closes this screen before the request finishes. What happens when the completion handler runs?

final class OrderViewController: UIViewController {
  func load() {
    api.fetchOrder { [unowned self] result in
      self.render(result)
    }
  }
}
Choose one answer

Discussion 0

Join free to post in the discussion.

Related questions