Update src/controllers/itemDetails/index.js

Co-authored-by: Bill Thornton <thornbill@users.noreply.github.com>
This commit is contained in:
DesertCookie 2020-10-18 11:53:31 +02:00 committed by GitHub
parent 746a6231fa
commit 9a5594149e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -172,7 +172,7 @@ function renderTrackSelections(page, instance, item, forceReload) {
var resolutionNames = []; var resolutionNames = [];
var sourceNames = []; var sourceNames = [];
mediaSources.forEach(function (v) { mediaSources.forEach(function (v) {
((v.Name.endsWith('p') || v.Name.endsWith('i'))) && !Number.isNaN(parseInt(v.Name, 10) ? resolutionNames.push(v) : sourceNames.push(v); (v.Name.endsWith('p') || v.Name.endsWith('i')) && !Number.isNaN(parseInt(v.Name, 10)) ? resolutionNames.push(v) : sourceNames.push(v);
}); });
resolutionNames.sort((a, b) => parseInt(b.Name, 10) - parseInt(a.Name, 10)); resolutionNames.sort((a, b) => parseInt(b.Name, 10) - parseInt(a.Name, 10));