Skip to content

Commit bf98024

Browse files
committed
LogFinder: use natural sort for params
Use localeCompare with numeric option to sort parameters naturally, matching the ordering used by MAVProxy and Mission Planner.
1 parent 659ffcf commit bf98024

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

LogFinder/LogFinder.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -386,7 +386,7 @@ function setup_table(logs) {
386386

387387
// Sort alphabetically, localeCompare does underscores differently to built in sort
388388
function param_sort(a, b) {
389-
return a.localeCompare(b)
389+
return a.localeCompare(b, undefined, {numeric: true})
390390
}
391391

392392
if (Object.keys(diff.added).length > 0) {

0 commit comments

Comments
 (0)