Skip to content

Instantly share code, notes, and snippets.

@NunoAlexandre
Last active July 17, 2019 11:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save NunoAlexandre/8fda4bf645434b81fa09f9fc24448f95 to your computer and use it in GitHub Desktop.
Save NunoAlexandre/8fda4bf645434b81fa09f9fc24448f95 to your computer and use it in GitHub Desktop.
observers.append(
NotificationCenter.default.addObserver(
forName: AVAudioSession.interruptionNotification,
object: nil,
queue: nil
)
{ [weak weakSelf = self] (notification) in
weakSelf?.onInterruption(notification)
}
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment