Fix for issue #1989

Fixes #1989
This commit is contained in:
Samantaz Fox 2021-04-07 15:13:41 +02:00 committed by GitHub
parent ae353cef2e
commit 93198438b8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -437,7 +437,8 @@ end
def get_playlist_videos(db, playlist, offset, locale = nil, continuation = nil)
# Show empy playlist if requested page is out of range
if offset >= playlist.video_count
# (e.g, when a new playlist has been created, offset will be negative)
if offset >= playlist.video_count || offset < 0
return [] of PlaylistVideo
end