diff --git a/src/services/inplayer.account.service.ts b/src/services/inplayer.account.service.ts index d25f7e9e8..5d6bab8b2 100644 --- a/src/services/inplayer.account.service.ts +++ b/src/services/inplayer.account.service.ts @@ -171,7 +171,7 @@ export const getPublisherConsents: GetPublisherConsents = async (config) => { const { data } = await InPlayer.Account.getRegisterFields(jwp?.clientId || ''); const result = data?.collection - .filter((field) => field.name !== 'email_confirmation') + .filter((field) => !['email_confirmation', 'first_name', 'surname'].includes(field.name)) .map( (field): Consent => ({ type: field.type as ConsentFieldVariants, @@ -215,7 +215,12 @@ export const getCustomerConsents: GetCustomerConsents = async (payload) => { export const updateCustomerConsents: UpdateCustomerConsents = async (payload) => { try { const { customer, consents } = payload; - const params = { ...formatUpdateAccount(customer), ...{ metadata: { consents: JSON.stringify(consents) } } }; + const params = { + ...formatUpdateAccount(customer), + metadata: { + consents: JSON.stringify(consents), + }, + }; const { data } = await InPlayer.Account.updateAccount(params);