1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-14 23:33:31 +00:00

[PM-16859] Fix item creation resetting to login item type on browser (#12765)

* Fix broken item creation on browser

* Fix creation of ssh keys items from a filtered vault resetting to login on web
This commit is contained in:
Bernd Schoolmann
2025-01-09 00:24:23 +01:00
committed by GitHub
parent bb61b3df3a
commit 0d5e4c6f58
2 changed files with 6 additions and 2 deletions

View File

@@ -50,7 +50,7 @@ export class NewItemDropdownV2Component implements OnInit {
this.tab = await BrowserApi.getTabFromCurrentWindow();
}
async buildQueryParams(type: CipherType): Promise<AddEditQueryParams> {
buildQueryParams(type: CipherType): AddEditQueryParams {
const poppedOut = BrowserPopupUtils.inPopout(window);
const loginDetails: { uri?: string; name?: string } = {};

View File

@@ -107,7 +107,11 @@ export class AddEditComponent extends BaseAddEditComponent implements OnInit, On
// https://bitwarden.atlassian.net/browse/PM-10413
// cannot generate ssh keys so block creation
if (this.type === CipherType.SshKey && this.cipherId == null) {
if (
this.type === CipherType.SshKey &&
this.cipherId == null &&
!(await this.configService.getFeatureFlag(FeatureFlag.SSHKeyVaultItem))
) {
this.type = CipherType.Login;
this.cipher.type = CipherType.Login;
}