mirror of
https://github.com/libre-tube/LibreTube.git
synced 2025-04-27 23:40:33 +05:30
fix again
This commit is contained in:
parent
751e2fda5f
commit
91b172d661
@ -951,12 +951,14 @@ class PlayerFragment : BaseFragment() {
|
||||
return
|
||||
}
|
||||
// browse the watch positions
|
||||
var position: Long? = null
|
||||
Thread {
|
||||
try {
|
||||
val position = DatabaseHolder.db.watchPositionDao().findById(videoId!!).position
|
||||
if (position < streams.duration!! * 0.9) exoPlayer.seekTo(position)
|
||||
position = DatabaseHolder.db.watchPositionDao().findById(videoId!!).position
|
||||
if (position!! < streams.duration!! * 0.9) position = null
|
||||
} catch (e: Exception) {}
|
||||
}.start()
|
||||
}.await()
|
||||
if (position != null) exoPlayer.seekTo(position!!)
|
||||
}
|
||||
|
||||
// used for autoplay and skipping to next video
|
||||
|
Loading…
x
Reference in New Issue
Block a user