Skip to content

Commit

Permalink
Don’t forget to invalidate CXProvider, thanks Apple! (#130)
Browse files Browse the repository at this point in the history
  • Loading branch information
ceaglest authored May 17, 2017
1 parent 100bebe commit 4e16414
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions VideoCallKitQuickStart/ViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,11 @@ class ViewController: UIViewController {
callKitProvider.setDelegate(self, queue: nil)
}

deinit {
// CallKit has an odd API contract where the developer must call invalidate or the CXProvider is leaked.
callKitProvider.invalidate()
}

// MARK: UIViewController
override func viewDidLoad() {
super.viewDidLoad()
Expand Down

0 comments on commit 4e16414

Please sign in to comment.