Skip to content

Commit 5ceda56

Browse files
committed
fix: tweak webhook exception message
1 parent 80e31f1 commit 5ceda56

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Modules/CIPPCore/Public/Entrypoints/Activity Triggers/Push-SchedulerCIPPNotifications.ps1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ function Push-SchedulerCIPPNotifications {
128128
Add-CIPPAzDataTableEntity @Table -Entity $UpdateLogs -Force
129129
}
130130
} catch {
131-
Write-Information "Could not send alerts to webhook: $($_.Exception.message)"
132-
Write-LogMessage -API 'Alerts' -message "Could not send alerts to : $($_.Exception.message)" -tenant $Tenant -sev error
131+
Write-Information "Could not send alerts to webhook $($config.webhook): $($_.Exception.message)"
132+
Write-LogMessage -API 'Alerts' -message "Could not send alerts to webhook $($config.webhook): $($_.Exception.message)" -tenant $Tenant -sev error -LogData (Get-CippException -Exception $_)
133133
}
134134

135135
if ($config.sendtoIntegration) {
@@ -157,4 +157,4 @@ function Push-SchedulerCIPPNotifications {
157157
}
158158

159159

160-
}
160+
}

0 commit comments

Comments
 (0)