Fixed Name & URI 1 Fields Populated Incorrectly when creating new Login in popout window (# 1816)

This commit is contained in:
arun 2021-05-05 13:59:42 -04:00
parent 8169922f84
commit f556b2a207
1 changed files with 6 additions and 15 deletions

View File

@ -75,22 +75,13 @@ export class AddEditComponent extends BaseAddEditComponent {
await this.load(); await this.load();
if (!this.editMode || this.cloneMode) { if (!this.editMode || this.cloneMode) {
if (params.name && (this.cipher.name == null || this.cipher.name === '')) { if (!this.popupUtilsService.inPopout(window) && params.name &&
if (this.popupUtilsService.inPopout(window)) { (this.cipher.name == null || this.cipher.name === '')) {
this.cipher.name = ''; this.cipher.name = params.name;
}
else {
this.cipher.name = params.name;
}
} }
if (params.uri && (this.cipher.login.uris[0].uri == null || this.cipher.login.uris[0].uri === '')) { if (!this.popupUtilsService.inPopout(window) && params.uri &&
if (this.popupUtilsService.inPopout(window)) { (this.cipher.login.uris[0].uri == null || this.cipher.login.uris[0].uri === '')) {
this.cipher.login.uris[0].uri = ''; this.cipher.login.uris[0].uri = params.uri;
}
else {
this.cipher.login.uris[0].uri = params.uri;
}
} }
} }
if (queryParamsSub != null) { if (queryParamsSub != null) {