mirror of
https://github.com/Ernous/TorrServerJellyfin.git
synced 2025-12-19 13:36:09 +05:00
fix reader pause if count 1
This commit is contained in:
@@ -135,7 +135,7 @@ func (r *Reader) getPieceNum(offset int64) int {
|
|||||||
|
|
||||||
func (r *Reader) getOffsetRange() (int64, int64) {
|
func (r *Reader) getOffsetRange() (int64, int64) {
|
||||||
|
|
||||||
if time.Now().Unix() > r.lastAccess+60 {
|
if time.Now().Unix() > r.lastAccess+60 && len(r.cache.readers) > 1 {
|
||||||
return r.file.Offset(), r.file.Offset()
|
return r.file.Offset(), r.file.Offset()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user