Fixed calling bindService if service is not running

This commit is contained in:
ByteHamster 2021-03-07 19:57:35 +01:00
parent 573cd2efd2
commit 7a3bb825ed

View File

@ -208,7 +208,9 @@ public abstract class PlaybackController {
handleStatus();
} else {
Log.w(TAG, "Couldn't receive status update: playbackService was null");
bindToService();
if (PlaybackService.isRunning) {
bindToService();
}
}
}
};
@ -232,7 +234,7 @@ public abstract class PlaybackController {
onBufferUpdate(progress);
break;
case PlaybackService.NOTIFICATION_TYPE_RELOAD:
if (playbackService == null) {
if (playbackService == null && PlaybackService.isRunning) {
bindToService();
return;
}