diff options
author | Flam3rboy <34555296+Flam3rboy@users.noreply.github.com> | 2021-09-16 20:49:12 +0200 |
---|---|---|
committer | Flam3rboy <34555296+Flam3rboy@users.noreply.github.com> | 2021-09-16 20:49:12 +0200 |
commit | 173f03c596c2df23b81d3c7601988f0e090e6e3a (patch) | |
tree | 6c98e2049eedffb4f0376a455efa8e564456eaa6 /api/src/routes/guilds | |
parent | Revert ":construction: webhook" (diff) | |
download | server-173f03c596c2df23b81d3c7601988f0e090e6e3a.tar.xz |
Revert "fix #129"
This reverts commit 8f862f0e5dba3985b4f38406fc19b5c5350324b9.
Diffstat (limited to 'api/src/routes/guilds')
-rw-r--r-- | api/src/routes/guilds/#guild_id/webhooks.ts | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/api/src/routes/guilds/#guild_id/webhooks.ts b/api/src/routes/guilds/#guild_id/webhooks.ts deleted file mode 100644 index a9dd164a..00000000 --- a/api/src/routes/guilds/#guild_id/webhooks.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { Router, Response, Request } from "express"; -import { route } from "@fosscord/api"; -import { Webhook } from "@fosscord/util"; - -const router: Router = Router(); - -router.get("/", route({ permission: "MANAGE_WEBHOOKS" }), async (req: Request, res: Response) => { - const webhooks = await Webhook.find({ - where: { guild_id: req.params.guild_id }, - select: ["application", "avatar", "channel_id", "guild_id", "id", "token", "type", "user", "source_guild", "name"], - relations: ["user", "application", "source_guild"] - }); - - return res.json(webhooks); -}); - -export default router; |