     private var playerItem: AVPlayerItem?
 
     // AVPlayerViewController.player paused by AVPlayerViewController when going into the background.
-    // So, on the background, detach the reference from AVPlayerViewController.
+    // So, on the background, remove the reference from AVPlayerViewController.
     private var player: AVPlayer? {
 
         didSet {


        self.backgroundColor = UIColor.blackColor()

        if #available(iOS 9.0, *) {

            self.avPlayerViewController.delegate = self.delegate
        }

        self.avPlayerViewController.addObserver(
            self,
            forKeyPath: avPlayerViewControllerReadyForDisplayKey,


    public var minimumBufferDuration: Double = 5.0

    public weak var delegate: KKPlayerViewControllerDelegate? {

        didSet {

            if #available(iOS 9.0, *) {

                self.avPlayerViewController.delegate = self.delegate
            }
        }
    }

    // MARK: Private properties

