mirror of
https://github.com/dreamhunter2333/cloudflare_temp_email.git
synced 2026-06-04 23:19:58 +08:00
feat: update webhook to support global webhook (#407)
This commit is contained in:
@@ -4,8 +4,8 @@ import { getEnvStringList } from "../utils";
|
||||
import { sendMailToTelegram } from "../telegram_api";
|
||||
import { Bindings, HonoCustomType } from "../types";
|
||||
import { auto_reply } from "./auto_reply";
|
||||
import { trigerWebhook } from "../mails_api/webhook_settings";
|
||||
import { isBlocked } from "./black_list";
|
||||
import { triggerWebhook } from "../common";
|
||||
|
||||
|
||||
async function email(message: ForwardableEmailMessage, env: Bindings, ctx: ExecutionContext) {
|
||||
@@ -48,7 +48,7 @@ async function email(message: ForwardableEmailMessage, env: Bindings, ctx: Execu
|
||||
|
||||
// send webhook
|
||||
try {
|
||||
await trigerWebhook(
|
||||
await triggerWebhook(
|
||||
{ env: env } as Context<HonoCustomType>,
|
||||
message.to, rawEmail
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user