Skip to content

Commit

Permalink
feat: generate anonymousId and move to component testcases
Browse files Browse the repository at this point in the history
  • Loading branch information
Gauravudia committed May 3, 2024
1 parent 2e22075 commit 447f85f
Show file tree
Hide file tree
Showing 4 changed files with 1,495 additions and 1,336 deletions.
2 changes: 2 additions & 0 deletions src/v0/sources/auth0/transform.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ const { getGroupId } = require('./util');
// import mapping json using JSON.parse to preserve object key order
const mapping = JSON.parse(fs.readFileSync(path.resolve(__dirname, './mapping.json'), 'utf-8'));
const Message = require('../message');
const { generateUUID } = require('../../util');

// Ref: https://auth0.com/docs/logs/references/log-event-type-codes
const eventNameMap = JSON.parse(
Expand Down Expand Up @@ -61,6 +62,7 @@ function processEvents(eventList) {

// eslint-disable-next-line camelcase
response.properties.log_id = log_id;
response.anonymousId = generateUUID();
responses.push(removeUndefinedAndNullValues(response));
}
});
Expand Down
23 changes: 0 additions & 23 deletions test/__tests__/auth0_source.test.js

This file was deleted.

Loading

0 comments on commit 447f85f

Please sign in to comment.