diff --git a/lib/icinga/plugin/New-IcingaCheckPackage.psm1 b/lib/icinga/plugin/New-IcingaCheckPackage.psm1 index 8d8428e..5c11fcb 100644 --- a/lib/icinga/plugin/New-IcingaCheckPackage.psm1 +++ b/lib/icinga/plugin/New-IcingaCheckPackage.psm1 @@ -35,6 +35,8 @@ function New-IcingaCheckPackage() } $Check | Add-Member -membertype ScriptMethod -name 'InitCheck' -value { + param($check); + if ($null -eq $check) { return; }