 			detachVC(player, nil, false)
 		}
         
-        if let mCastPlayer = castPlayer {
-            castPlayer?.destroy()
-        }
-        
         if let mCastPlayerController = castPlayerController {
             detachVC(mCastPlayerController, nil, false)
         }

		NotificationCenter.default.removeObserver(self)
		_isFullscreen = false
		_player = nil
        castPlayer = nil
        castPlayerController = nil
        

                SambaCast.sharedInstance.unSubscribe(delegate: self)
            }
        }
    }
    
    
    private func getCastCaptionFormat() -> String? {
        guard let mCaptionScreen = _captionsScreen as? CaptionsScreen,
        mCaptionScreen.hasCaptions,
        let mCaptions = media.captions, mCaptions.count > 0 else {
            return nil
        }
        
        let currentCaptionIndex = mCaptionScreen.currentIndex
        
        let currentCaption = mCaptions[currentCaptionIndex]
        
        return String(format: "[%s,ffcc00,42]", currentCaption.language)
    }
    
    
