summary refs log tree commit diff
path: root/api/src/routes/guilds/#guild_id/channels.ts
diff options
context:
space:
mode:
Diffstat (limited to 'api/src/routes/guilds/#guild_id/channels.ts')
-rw-r--r--api/src/routes/guilds/#guild_id/channels.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/api/src/routes/guilds/#guild_id/channels.ts b/api/src/routes/guilds/#guild_id/channels.ts
index e3c6b8bd..b952b474 100644
--- a/api/src/routes/guilds/#guild_id/channels.ts
+++ b/api/src/routes/guilds/#guild_id/channels.ts
@@ -7,7 +7,7 @@ const router = Router();
 
 router.get("/", route({}), async (req: Request, res: Response) => {
 	const { guild_id } = req.params;
-	const channels = await Channel.find({ guild_id });
+	const channels = await Channel.find({ where: { guild_id } });
 
 	res.json(channels);
 });
@@ -48,7 +48,7 @@ router.patch("/", route({ body: "ChannelReorderSchema", permission: "MANAGE_CHAN
 			}
 
 			await Channel.update({ guild_id, id: x.id }, opts);
-			const channel = await Channel.findOneOrFail({ guild_id, id: x.id });
+			const channel = await Channel.findOneOrFail({ where: { guild_id, id: x.id } });
 
 			await emitEvent({ event: "CHANNEL_UPDATE", data: channel, channel_id: x.id, guild_id } as ChannelUpdateEvent);
 		})