Prevent iOS crash when disposing player before FlutterEngine is destroyed.
This commit is contained in:
parent
7949f92b90
commit
d2de8a89f9
|
@ -1157,7 +1157,9 @@
|
|||
if (_processingState != none) {
|
||||
[_player pause];
|
||||
_processingState = none;
|
||||
[self broadcastPlaybackEvent];
|
||||
// If used just before destroying the current FlutterEngine, this will result in:
|
||||
// NSInternalInconsistencyException: 'Sending a message before the FlutterEngine has been run.'
|
||||
//[self broadcastPlaybackEvent];
|
||||
}
|
||||
if (_timeObserver) {
|
||||
[_player removeTimeObserver:_timeObserver];
|
||||
|
|
Loading…
Reference in New Issue