From a1029f0ccd85ba658ad9a087219a13a5b39e8459 Mon Sep 17 00:00:00 2001 From: Brian Miller Date: Wed, 27 Sep 2023 12:46:17 -0500 Subject: [PATCH] cleanup --- packages/marko-web-identity-x/config.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/marko-web-identity-x/config.js b/packages/marko-web-identity-x/config.js index fb07cd8ee..dad3ade80 100644 --- a/packages/marko-web-identity-x/config.js +++ b/packages/marko-web-identity-x/config.js @@ -29,7 +29,7 @@ class IdentityXConfiguration { hiddenFields = ['city', 'street', 'addressExtra', 'phoneNumber'], defaultCountryCode, booleanQuestionsLabel, - gtmUserFields = {}, // { primary_role: 'ObjectId' } + gtmUserFields = {}, onHookError, ...rest } = {}) { @@ -115,9 +115,9 @@ class IdentityXConfiguration { const questions = this.getAsObject('gtmUserFields'); const userData = { user_id: user.id }; Object.entries(questions).forEach(([key, value]) => { - const select = user.customSelectFieldAnswers.find(({ id }) => id === value) - if (select && select.answers.length) userData[key] = select.answers.map(({ label }) => label).join("|"); - const boolean = user.customBooleanFieldAnswers.find(({ id }) => id === value) + const select = user.customSelectFieldAnswers.find(({ id }) => id === value); + if (select && select.answers.length) userData[key] = select.answers.map(({ label }) => label).join('|'); + const boolean = user.customBooleanFieldAnswers.find(({ id }) => id === value); if (boolean && boolean.hasAnswered) userData[key] = boolean.answer; }); return userData;