1
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2025-09-05 12:27:55 +00:00

Apply Kotlin suggestion by @Isira-Seneviratne

This commit is contained in:
Stypox
2025-07-16 15:07:04 +02:00
parent 3998982002
commit 046ea7301b

View File

@@ -1931,12 +1931,8 @@ class VideoDetailFragment :
} }
private fun findQueueInStack(queue: PlayQueue): StackItem? { private fun findQueueInStack(queue: PlayQueue): StackItem? {
stack.descendingIterator().forEach { item -> return stack.descendingIterator().asSequence()
if (item?.playQueue == queue) { .firstOrNull { it?.playQueue?.equals(queue) == true }
return@findQueueInStack item
}
}
return null
} }
private fun replaceQueueIfUserConfirms(onAllow: Runnable) { private fun replaceQueueIfUserConfirms(onAllow: Runnable) {