Skip to content

Commit e51b591

Browse files
committed
Fix name of env var
1 parent fa4caff commit e51b591

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/functions/teams_notifier.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,14 +50,14 @@ function validateTeamsWebhook(webhook: string): string | null {
5050

5151
export const notifyTeams = async (eventData: SecretScanningAlertWebHookPayload) => {
5252
// get Teams webhook out of app settings in Azure Function
53-
const teamsWebhook = process.env.TEAMS_WEBHOOK;
53+
const teamsWebhook = process.env.TEAMS_WEBHOOK_URL;
5454

5555
if (!teamsWebhook) {
56-
throw new Error("TEAMS_WEBHOOK is not set");
56+
throw new Error("TEAMS_WEBHOOK_URL is not set");
5757
}
5858

5959
if (!validateTeamsWebhook(teamsWebhook)) {
60-
throw new Error("TEAMS_WEBHOOK is not valid");
60+
throw new Error("TEAMS_WEBHOOK_URL is not valid");
6161
}
6262

6363
// notify Teams using the webhook

0 commit comments

Comments
 (0)