From 5fa630aac27e9ba2920edd3baf6a9d78eedf4661 Mon Sep 17 00:00:00 2001 From: Cesar Gonzalez Date: Tue, 7 Nov 2023 07:37:30 -0600 Subject: [PATCH] [PM-4590] Cached Page Details of Formless Input Fields Breaks Autofill (#6726) --- .../autofill/services/collect-autofill-content.service.ts | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/apps/browser/src/autofill/services/collect-autofill-content.service.ts b/apps/browser/src/autofill/services/collect-autofill-content.service.ts index 4780c294ab1..caf9060dd21 100644 --- a/apps/browser/src/autofill/services/collect-autofill-content.service.ts +++ b/apps/browser/src/autofill/services/collect-autofill-content.service.ts @@ -47,11 +47,7 @@ class CollectAutofillContentService implements CollectAutofillContentServiceInte return this.getFormattedPageDetails({}, []); } - if ( - !this.domRecentlyMutated && - this.autofillFormElements.size && - this.autofillFieldElements.size - ) { + if (!this.domRecentlyMutated && this.autofillFieldElements.size) { return this.getFormattedPageDetails( this.getFormattedAutofillFormsData(), this.getFormattedAutofillFieldsData() @@ -66,7 +62,7 @@ class CollectAutofillContentService implements CollectAutofillContentServiceInte ); this.sortAutofillFieldElementsMap(); - if (!Object.values(autofillFormsData).length || !autofillFieldsData.length) { + if (!autofillFieldsData.length) { this.noFieldsFound = true; }