From 5f811489c88fed79b7697bf5752cc96191d40ba5 Mon Sep 17 00:00:00 2001 From: Cesar Gonzalez Date: Wed, 22 May 2024 07:40:43 -0500 Subject: [PATCH] [PM-5189] Adjusting an implementation detail when collection page details --- .../services/collect-autofill-content.service.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 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 5ffee71f4f..0d4b718123 100644 --- a/apps/browser/src/autofill/services/collect-autofill-content.service.ts +++ b/apps/browser/src/autofill/services/collect-autofill-content.service.ts @@ -1312,14 +1312,14 @@ class CollectAutofillContentService implements CollectAutofillContentServiceInte continue; } - const isViewable = - await this.domElementVisibilityService.isFormFieldViewable(formFieldElement); - if (!isViewable) { + const cachedAutofillFieldElement = this.autofillFieldElements.get(formFieldElement); + if (!cachedAutofillFieldElement) { continue; } - const cachedAutofillFieldElement = this.autofillFieldElements.get(formFieldElement); - if (!cachedAutofillFieldElement) { + const isViewable = + await this.domElementVisibilityService.isFormFieldViewable(formFieldElement); + if (!isViewable) { continue; }