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:
@@ -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 } = {};
|
||||
|
||||
@@ -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;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user