mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-13 22:54:42 -04:00
refactor(backend): don't create local user if password is too weak
This prevents the previous problem that the backend created a user that was then not correctly removed again Signed-off-by: Philip Molares <philip.molares@udo.edu>
This commit is contained in:
parent
45e70434c4
commit
47d1765b12
2 changed files with 3 additions and 2 deletions
|
@ -58,6 +58,7 @@ export class AuthController {
|
|||
@Req() request: RequestWithSession,
|
||||
@Body() registerDto: RegisterDto,
|
||||
): Promise<void> {
|
||||
await this.identityService.checkPasswordStrength(registerDto.password);
|
||||
const user = await this.usersService.createUser(
|
||||
registerDto.username,
|
||||
registerDto.displayName,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue