From 4823cf940f3b77b1eacb8b0fd183d3def43f741d Mon Sep 17 00:00:00 2001 From: "Wyatt J. Miller" Date: Wed, 16 Jun 2021 21:05:10 -0400 Subject: [PATCH] fixes --- disk_check.ps1 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/disk_check.ps1 b/disk_check.ps1 index 3f4355d..fc2499a 100644 --- a/disk_check.ps1 +++ b/disk_check.ps1 @@ -24,7 +24,7 @@ Function Write-Log{ foreach ($i in $volumes) { if ($i.FileSystemLabel -eq "") { - Write-Output "" + Write-Output } else { $result=Repair-Volume -FileSystemLabel $i.FileSystemLabel -Scan @@ -32,8 +32,8 @@ foreach ($i in $volumes) { Repair-Volume -FileSystemLabel $i.FileSystemLabel -Scan -OfflineScanAndFix $requireReboot = $true } else { - Write-Output $i.FileSystemLabel + ": Drive is OK!" - Write-Log $now + ',' + $i.FileSystemLabel + ',' + $result + ',' + $targetComputer + Write-Output "$($i.FileSystemLabel): Drive is OK!" + Write-Log "$($now), $($i.FileSystemLabel), $($result), $($computerName)" } } }