From 2654936c1746a69459f8066ca785efd722e527fa Mon Sep 17 00:00:00 2001 From: syuilo Date: Fri, 13 Jan 2023 17:42:12 +0900 Subject: [PATCH] fix --- .../backend/src/server/api/endpoints/i/webhooks/update.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/backend/src/server/api/endpoints/i/webhooks/update.ts b/packages/backend/src/server/api/endpoints/i/webhooks/update.ts index 50098f96e7..8ec308eda7 100644 --- a/packages/backend/src/server/api/endpoints/i/webhooks/update.ts +++ b/packages/backend/src/server/api/endpoints/i/webhooks/update.ts @@ -67,7 +67,11 @@ export default class extends Endpoint { active: ps.active, }); - this.globalEventService.publishInternalEvent('webhookUpdated', webhook); + const updated = await this.webhooksRepository.findOneByOrFail({ + id: ps.webhookId, + }); + + this.globalEventService.publishInternalEvent('webhookUpdated', updated); }); } }