refactor(core): Continue moving typeorm operators to repositories (no-changelog) (#8186)

Follow-up to: #8163
This commit is contained in:
Iván Ovejero
2024-01-02 17:53:24 +01:00
committed by GitHub
parent 0ca2759d75
commit 40c1eeeddd
35 changed files with 341 additions and 354 deletions

View File

@@ -138,7 +138,7 @@ export class AuthController {
}
try {
user = await this.userService.findOneOrFail({ where: {} });
user = await this.userRepository.findOneOrFail({ where: {}, relations: ['globalRole'] });
} catch (error) {
throw new InternalServerError(
'No users found in database - did you wipe the users table? Create at least one user.',