From 7d89c109541dd2a7000bdb3206cfe0005a75aebc Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Wed, 19 Nov 2025 22:54:05 -0600 Subject: [PATCH] Update vCenter-SSL.ps1 --- inc/vCenter-SSL.ps1 | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/inc/vCenter-SSL.ps1 b/inc/vCenter-SSL.ps1 index 45734342..d0ccaf0f 100644 --- a/inc/vCenter-SSL.ps1 +++ b/inc/vCenter-SSL.ps1 @@ -31,7 +31,11 @@ function Write-Log { $ts = Get-Date -Format 'yyyy-MM-dd HH:mm:ss' $line = "[$ts] $Level : $Message" - Write-Host $line -ForegroundColor $ForegroundColor + if ($ForegroundColor) { + Write-Host $line -ForegroundColor $ForegroundColor + } else { + Write-Host $line + } try { $dir = Split-Path $LogFile if (-not (Test-Path $dir)) {