replace '@me' with req.user_id in guild join

This commit is contained in:
xnacly 2021-09-03 21:33:25 +02:00
parent 94c96be0ee
commit 1211e486f9

View File

@ -51,7 +51,8 @@ router.patch("/", check(MemberChangeSchema), async (req: Request, res: Response)
});
router.put("/", async (req: Request, res: Response) => {
const { guild_id, member_id } = req.params;
let { guild_id, member_id } = req.params;
if (member_id === "@me") member_id = req.user_id;
throw new HTTPError("Maintenance: Currently you can't add a member", 403);
// TODO: only for oauth2 applications