From 6e972bb5d39a52d78f5b6b6bdec3e688c7f5849f Mon Sep 17 00:00:00 2001 From: Markus Fleschutz Date: Sat, 29 Oct 2022 18:25:55 +0200 Subject: [PATCH] Update check-smart-devices.ps1 --- Scripts/check-smart-devices.ps1 | 2 -- 1 file changed, 2 deletions(-) diff --git a/Scripts/check-smart-devices.ps1 b/Scripts/check-smart-devices.ps1 index 9eb19f3e..d77ce44e 100755 --- a/Scripts/check-smart-devices.ps1 +++ b/Scripts/check-smart-devices.ps1 @@ -52,9 +52,7 @@ try { if ($lastExitCode -ne "0") { throw "'sudo smartctl --test=short $Device' exited with error code $lastExitCode" } } else { $Details = (smartctl --all --json $Device) | ConvertFrom-Json - if ($lastExitCode -ne "0") { throw "'smartctl --all --json $Device' exited with error code $lastExitCode" } $null = (smartctl --test=short $Device) - if ($lastExitCode -ne "0") { throw "'smartctl --test=short $Device' exited with error code $lastExitCode" } } $ModelName = $Details.model_name $Protocol = $Details.device.protocol