From e47bfc85cc108edf572dda4c422e469595d3d300 Mon Sep 17 00:00:00 2001 From: taskylizard <75871323+taskylizard@users.noreply.github.com> Date: Sat, 4 Nov 2023 22:29:51 +0530 Subject: [PATCH] fix --- .github/workflows/deploy-api.yml | 1 + .vitepress/routes/index.post.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/deploy-api.yml b/.github/workflows/deploy-api.yml index 9a3246ef3..e994eff96 100644 --- a/.github/workflows/deploy-api.yml +++ b/.github/workflows/deploy-api.yml @@ -31,6 +31,7 @@ jobs: - name: Build run: pnpm api:build env: + WEBHOOK_URL: ${{ secrets.WEBHOOK_URL }} NITRO_PRESET: cloudflare - name: Publish to Cloudflare diff --git a/.vitepress/routes/index.post.ts b/.vitepress/routes/index.post.ts index 7d7a9789b..3a2eebb72 100644 --- a/.vitepress/routes/index.post.ts +++ b/.vitepress/routes/index.post.ts @@ -30,7 +30,7 @@ export default defineEventHandler(async (event) => { if (!["bug", "suggestion", "other", "appreciate"].includes(feedbackType!) || !message) { throw new Error("Invalid input."); } - console.log(env.WEBHOOK_URL); + console.log(env.WEBHOOK_URL, process.env.WEBHOOK_URL); await fetcher() .post(env.WEBHOOK_URL, { username: "Feedback",