summary refs log tree commit diff
path: root/api/src/routes
diff options
context:
space:
mode:
authorMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2022-08-21 20:00:35 +1000
committerMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2022-08-21 20:00:35 +1000
commitc7767e5fa4f392cb06502fd928a977b10e404918 (patch)
tree92f67fcdbf3d1e38e82f61df7f95f22146e255bc /api/src/routes
parentfosscord-server/pulls/858 (diff)
downloadserver-c7767e5fa4f392cb06502fd928a977b10e404918.tar.xz
Fix /users/@me/settings get and migrarion
Diffstat (limited to 'api/src/routes')
-rw-r--r--api/src/routes/users/@me/settings.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/api/src/routes/users/@me/settings.ts b/api/src/routes/users/@me/settings.ts
index 50a00cac..787ea9d4 100644
--- a/api/src/routes/users/@me/settings.ts
+++ b/api/src/routes/users/@me/settings.ts
@@ -4,13 +4,13 @@ import { route } from "@fosscord/api";
 
 const router = Router();
 
-export interface UserSettingsSchema extends Partial<UserSettings> {}
+export interface UserSettingsSchema extends Partial<UserSettings> { }
 
 router.get("/", route({}), async (req: Request, res: Response) => {
 	const user = await User.findOneOrFail(
 		{ id: req.user_id },
-		{ relations: ["settings"] }
-	)
+		{ select: ["settings"] }
+	);
 	return res.json(user.settings);
 });