From 7c96c5706c793cea1f19e09bc80aac818816d7a3 Mon Sep 17 00:00:00 2001 From: Lint Action Date: Thu, 21 Apr 2022 18:04:42 +0000 Subject: [PATCH] Fix code style issues with ESLint --- ereuse_devicehub/static/js/main_inventory.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ereuse_devicehub/static/js/main_inventory.js b/ereuse_devicehub/static/js/main_inventory.js index ce107ac8..c230363d 100644 --- a/ereuse_devicehub/static/js/main_inventory.js +++ b/ereuse_devicehub/static/js/main_inventory.js @@ -393,10 +393,10 @@ async function processSelectedDevices() { }) - var lotsList = []; - lotsList.push(lots.filter(lot => lot.state == "true").sort((a,b) => a["name"].localeCompare(b["name"]))); - lotsList.push(lots.filter(lot => lot.state == "indetermined").sort((a,b) => a["name"].localeCompare(b["name"]))); - lotsList.push(lots.filter(lot => lot.state == "false").sort((a,b) => a["name"].localeCompare(b["name"]))); + let lotsList = []; + lotsList.push(lots.filter(lot => lot.state == "true").sort((a,b) => a.name.localeCompare(b.name))); + lotsList.push(lots.filter(lot => lot.state == "indetermined").sort((a,b) => a.name.localeCompare(b.name))); + lotsList.push(lots.filter(lot => lot.state == "false").sort((a,b) => a.name.localeCompare(b.name))); lotsList = lotsList.flat(); // flat array listHTML.html("");