mirror of
https://github.com/bitwarden/browser
synced 2025-12-17 00:33:44 +00:00
enforce policies on generate command (#115)
This commit is contained in:
@@ -35,7 +35,8 @@ export class GenerateCommand {
|
||||
} else if (options.wordSeparator != null && options.wordSeparator.length > 1) {
|
||||
options.wordSeparator = options.wordSeparator[0];
|
||||
}
|
||||
const password = await this.passwordGenerationService.generatePassword(options);
|
||||
const enforcedOptions = await this.passwordGenerationService.enforcePasswordGeneratorPoliciesOnOptions(options);
|
||||
const password = await this.passwordGenerationService.generatePassword(enforcedOptions[0]);
|
||||
const res = new StringResponse(password);
|
||||
return Response.success(res);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user