Skip to content

Commit

Permalink
feat: remove redundant data from traits in hubspot
Browse files Browse the repository at this point in the history
  • Loading branch information
ItsSudip committed Apr 17, 2024
1 parent 0b57204 commit ab153f0
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion src/v0/destinations/hs/HSTransform-v2.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,11 @@ const processIdentify = async (message, destination, propertyMap) => {
GENERIC_TRUE_VALUES.includes(mappedToDestination.toString()) &&
operation
) {
addExternalIdToHSTraits(message);
if (!objectType) {
throw new InstrumentationError('objectType not found');
}
if (operation === 'createObject') {
addExternalIdToHSTraits(message);
endpoint = CRM_CREATE_UPDATE_ALL_OBJECTS.replace(':objectType', objectType);
} else if (operation === 'updateObject' && getHsSearchId(message)) {
const { hsSearchId } = getHsSearchId(message);
Expand Down
1 change: 0 additions & 1 deletion test/integrations/destinations/hs/processor/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1534,7 +1534,6 @@ export const data = [
firstname: 'Test Hubspot',
anonymousId: '12345',
country: 'India',
email: '[email protected]',
},
},
XML: {},
Expand Down
1 change: 0 additions & 1 deletion test/integrations/destinations/hs/router/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1033,7 +1033,6 @@ export const data = [
firstname: 'Test Hubspot',
anonymousId: '12345',
country: 'India',
email: '[email protected]',
},
id: '103605',
},
Expand Down

0 comments on commit ab153f0

Please sign in to comment.