* fix(ios): destroy adsManager when player detach from super view (#3716) * fix: swift format
This commit is contained in:
committed by
GitHub
parent
ecc946d1c1
commit
e96c17321f
@@ -44,6 +44,16 @@
|
||||
}
|
||||
}
|
||||
|
||||
func releaseAds() {
|
||||
guard let adsManager else { return }
|
||||
// Destroy AdsManager may be delayed for a few milliseconds
|
||||
// But what we want is it stopped producing sound immediately
|
||||
// Issue found on tvOS 17, or iOS if view detach & STARTED event happen at the same moment
|
||||
adsManager.volume = 0
|
||||
adsManager.pause()
|
||||
adsManager.destroy()
|
||||
}
|
||||
|
||||
// MARK: - Getters
|
||||
|
||||
func getAdsLoader() -> IMAAdsLoader? {
|
||||
|
Reference in New Issue
Block a user