Skip to content

Commit

Permalink
fix: sort videos
Browse files Browse the repository at this point in the history
  • Loading branch information
vitalygashkov committed May 12, 2024
1 parent 80ef8a0 commit d73717d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/dash.js
Original file line number Diff line number Diff line change
Expand Up @@ -406,6 +406,8 @@ const parseManifest = async (text, url, fallbackLanguage) => {
}
}

videos.sort((a, b) => b.bitrate.bps - a.bitrate.bps);

return {
duration,
tracks: {
Expand Down

0 comments on commit d73717d

Please sign in to comment.