From 1acb94750408490ce89264f92a14aceeffe81c96 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Mon, 11 Jan 2021 13:53:08 +0100 Subject: Retrieve user by id instead of username --- server/controllers/api/users/me.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'server/controllers/api/users') diff --git a/server/controllers/api/users/me.ts b/server/controllers/api/users/me.ts index b786d7f59..7ab089713 100644 --- a/server/controllers/api/users/me.ts +++ b/server/controllers/api/users/me.ts @@ -130,7 +130,7 @@ async function getUserVideoImports (req: express.Request, res: express.Response) async function getUserInformation (req: express.Request, res: express.Response) { // We did not load channels in res.locals.user - const user = await UserModel.loadForMeAPI(res.locals.oauth.token.user.username) + const user = await UserModel.loadForMeAPI(res.locals.oauth.token.user.id) return res.json(user.toMeFormattedJSON()) } -- cgit v1.2.3