Skip to content

Commit 447be72

Browse files
committed
Fixes check reporting ok while state is non-ok
1 parent 92e3171 commit 447be72

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

plugins/Invoke-IcingaCheckMSSQLHealth.psm1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ function Invoke-IcingaCheckMSSQLHealth()
7878
# Create a unique name for our timer
7979
[string]$MSSQLTimer = [string]::Format('MSSQL_Timer_{0}', $Instance);
8080
# Start the timer to store our connection time
81-
Start-IcingaTimer $MSSQLTimer;
81+
Start-IcingaTimer $MSSQLTimer | Out-Null;
8282
# Connect to MSSQL
8383
$SqlConnection = Open-IcingaMSSQLConnection -Username $SqlUsername -Password $SqlPassword -Address $SqlHost -IntegratedSecurity:$IntegratedSecurity -Port $SqlPort -SqlDatabase $SqlDatabase -TestConnection;
8484
# Stop the timer
@@ -128,5 +128,5 @@ function Invoke-IcingaCheckMSSQLHealth()
128128

129129
$MSSQLCheckPackage.AddCheck($MSSQLConnCheck);
130130

131-
return (New-IcingaCheckResult -Check $MSSQLCheckPackage -Compile -NoPerfData $NoPerfData)
131+
return (New-IcingaCheckResult -Check $MSSQLCheckPackage -Compile -NoPerfData $NoPerfData);
132132
}

0 commit comments

Comments
 (0)