Skip to content

Commit

Permalink
Revert "Apply suggestions from code review"
Browse files Browse the repository at this point in the history
This reverts commit fc3def4.
  • Loading branch information
shrouti1507 committed Apr 25, 2024
1 parent fc3def4 commit 561b93e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/cdk/v2/destinations/algolia/procWorkflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,11 @@ steps:
$.assert(.message.properties.index, 'Missing required value from "properties.index"');
let eventTypeMap = $.eventTypeMapping(.destination.Config);
let event = .message.event.trim().toLowerCase();
let eventType = .message.properties?.eventType ?? eventTypeMap[event];
let eventSubType = .message.properties?.eventSubtype in $.ALLOWED_EVENT_SUBTYPES && eventType === 'conversion' ? .message.properties.eventSubtype: null;
let eventType = .message.properties.eventType ?? eventTypeMap[event];
let eventSubType = .message.properties.eventSubtype && eventType === 'conversion' ?
.message.properties.eventSubtype in $.ALLOWED_EVENT_SUBTYPES ?
.message.properties.eventSubtype : null
: null;
$.assert(eventType, "eventType is mandatory for track call");
let payload = .message.().({
index: .properties.index,
Expand Down

0 comments on commit 561b93e

Please sign in to comment.