1
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2025-09-01 10:27:57 +00:00

Player/handleIntent: de morgan samePlayQueue

Okay, so this is the … only? branch in this if-chain that will
conditionally fire if `playQueue` *is* `null`, sometimes.

This is why the unconditional `initPlayback` in `else` is not passed a
`null` in many cases … because `RESUME_PLAYBACK` is `true` and
`playQueue` is `null`.

It’s gonna be hard to figure out which parts of that are intentional,
I say.
This commit is contained in:
Profpatsch
2025-05-04 21:07:35 +02:00
parent 007ff478f7
commit 295acc41e1

View File

@@ -431,7 +431,8 @@ public final class Player implements PlaybackListener, Listener {
} else if (intent.getBooleanExtra(RESUME_PLAYBACK, false)
&& DependentPreferenceHelper.getResumePlaybackEnabled(context)
&& !samePlayQueue
// !samePlayQueue
&& (playQueue == null || !playQueue.equalStreamsAndIndex(newQueue))
&& !newQueue.isEmpty()
&& newQueue.getItem() != null
&& newQueue.getItem().getRecoveryPosition() == PlayQueueItem.RECOVERY_UNSET) {