summary refs log tree commit diff
path: root/api/src/routes/guilds/templates
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-09-03 03:37:55 +0200
committerFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-09-03 03:37:55 +0200
commit36fe0ec0c8022cbbde23eb87ca00906629255de6 (patch)
tree43dba167ea6e790ac271b05710c41a539a0fd0d3 /api/src/routes/guilds/templates
parentfix #309 (diff)
downloadserver-36fe0ec0c8022cbbde23eb87ca00906629255de6.tar.xz
:bug: fix member + member list
Diffstat (limited to 'api/src/routes/guilds/templates')
-rw-r--r--api/src/routes/guilds/templates/index.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/api/src/routes/guilds/templates/index.ts b/api/src/routes/guilds/templates/index.ts
index 16b65c65..3a619278 100644
--- a/api/src/routes/guilds/templates/index.ts
+++ b/api/src/routes/guilds/templates/index.ts
@@ -20,7 +20,7 @@ router.post("/:code", check(GuildTemplateCreateSchema), async (req: Request, res
 
 	const { maxGuilds } = Config.get().limits.user;
 
-	const guild_count = await Member.count({ user_id: req.user_id });
+	const guild_count = await Member.count({ id: req.user_id });
 	if (guild_count >= maxGuilds) {
 		throw DiscordApiErrors.MAXIMUM_GUILDS.withParams(maxGuilds);
 	}