Fix hdd sorting for >10 hdds (#163)

This commit is contained in:
Meliox 2026-05-11 20:00:53 +02:00 committed by GitHub
parent 6a27678594
commit ea98856365
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1218,7 +1218,7 @@ generate_hdd_widget() {
} catch(e) { } catch(e) {
objValue = {}; objValue = {};
} }
const drvKeys = Object.keys(objValue).filter(item => String(item).startsWith(addressPrefix)).sort(); const drvKeys = Object.keys(objValue).filter(item => String(item).startsWith(addressPrefix)).sort((a, b) => a.localeCompare(b, undefined, { numeric: true, sensitivity: 'base' }));
let temps = []; let temps = [];
drvKeys.forEach((drvKey, index) => { drvKeys.forEach((drvKey, index) => {
try { try {