From 0d80957639e5cc0cfa67c28be1e381a197a123aa Mon Sep 17 00:00:00 2001 From: Jonas Hermsmeier Date: Thu, 6 Sep 2018 15:18:16 +0200 Subject: [PATCH] gui: Also blacklist match against device & raw path This fixes device blacklist handling to also match against `drive.device` and `drive.raw`, in order to be able to specify devices lacking a `devicePath`. Change-type: patch Signed-off-by: Jonas Hermsmeier --- lib/gui/app/app.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/gui/app/app.js b/lib/gui/app/app.js index 015e50f2..f8e94e95 100644 --- a/lib/gui/app/app.js +++ b/lib/gui/app/app.js @@ -242,7 +242,9 @@ app.run(($timeout) => { $timeout(() => { if (BLACKLISTED_DRIVES.length) { const allowedDrives = drives.filter((drive) => { - return !BLACKLISTED_DRIVES.includes(drive.devicePath) + return !(BLACKLISTED_DRIVES.includes(drive.devicePath) || + BLACKLISTED_DRIVES.includes(drive.device) || + BLACKLISTED_DRIVES.includes(drive.raw)) }) availableDrives.setDrives(allowedDrives) } else {