[PM-8833] Refactoring implementation

This commit is contained in:
Cesar Gonzalez 2024-09-30 11:40:32 -05:00
parent 7efae38745
commit 684f7717eb
No known key found for this signature in database
GPG Key ID: 3381A5457F8CCECF
2 changed files with 9 additions and 6 deletions

View File

@ -702,11 +702,15 @@ export class OverlayBackground implements OverlayBackgroundInterface {
? focusedFieldData.inlineMenuFillType
: this.focusedFieldData?.inlineMenuFillType;
return (
(focusedFieldFillType === InlineMenuFillType.CurrentPasswordUpdate &&
fillType === CipherType.Login) ||
focusedFieldFillType === fillType
);
// When updating the current password for a field, it should fill with a login cipher
if (
focusedFieldFillType === InlineMenuFillType.CurrentPasswordUpdate &&
fillType === CipherType.Login
) {
return true;
}
return focusedFieldFillType === fillType;
}
/**

View File

@ -187,7 +187,6 @@ export class AutofillOverlayContentService implements AutofillOverlayContentServ
autofillFieldData: AutofillField,
pageDetails: AutofillPageDetails,
) {
// TODO: Might want to look into handling this sandbox iframe check a bit more effectively.
if (
currentlyInSandboxedIframe() ||
this.formFieldElements.has(formFieldElement) ||