Update backend/src/graphql/resolver/UserResolver.ts

Co-authored-by: Moriz Wahl <moriz.wahl@gmx.de>
This commit is contained in:
Ulf Gebhardt 2023-02-02 02:02:41 +01:00 committed by GitHub
parent 46eb45a14e
commit 064e3221bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -722,7 +722,7 @@ export class UserResolver {
const user = await DbUser.findOne({ id: userId })
// user exists ?
if (!user) {
throw new LogError(`Could not find user with userId: ${userId}`, userId)
throw new LogError('Could not find user with given ID', userId)
}
// administrator user changes own role?
const moderatorUser = getUser(context)