Commit 6f4880b7 authored by Felix Paul Kühne's avatar Felix Paul Kühne

playback: add missing exception handling

parent 0fb4d35f
......@@ -468,8 +468,14 @@
- (void)_stopPlayback
{
if (_mediaPlayer) {
[_mediaPlayer removeObserver:self forKeyPath:@"time"];
[_mediaPlayer removeObserver:self forKeyPath:@"remainingTime"];
@try {
[_mediaPlayer removeObserver:self forKeyPath:@"time"];
[_mediaPlayer removeObserver:self forKeyPath:@"remainingTime"];
}
@catch (NSException *exception) {
APLog(@"we weren't an observer yet");
}
[_mediaPlayer pause];
[self _saveCurrentState];
[_mediaPlayer stop];
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment