@blotoutio/providers-snapchat-sdk 0.25.0 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +7 -4
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -161,7 +161,11 @@ var ProvidersSnapchatSdk = (function () {
|
|
|
161
161
|
}
|
|
162
162
|
return name.toUpperCase();
|
|
163
163
|
};
|
|
164
|
-
const tag = ({ data, eventName, manifestVariables, eventId }) => {
|
|
164
|
+
const tag = ({ data, eventName, manifestVariables, eventId, executionContext, }) => {
|
|
165
|
+
const result = { sdkVersion: "0.26.0" };
|
|
166
|
+
if (executionContext.get('pixelFired')) {
|
|
167
|
+
return result;
|
|
168
|
+
}
|
|
165
169
|
if (window.snaptr && manifestVariables['enableBrowser'] === '1') {
|
|
166
170
|
const event = data['skipTransformation'] === true
|
|
167
171
|
? eventName
|
|
@@ -169,6 +173,7 @@ var ProvidersSnapchatSdk = (function () {
|
|
|
169
173
|
const eventData = data['skipTransformation'] === true ? data : prepareData(data);
|
|
170
174
|
delete eventData['skipTransformation'];
|
|
171
175
|
if (STANDARD_SNAPCHAT_EVENTS.has(event)) {
|
|
176
|
+
executionContext.set('pixelFired', true);
|
|
172
177
|
window.snaptr('track', event, {
|
|
173
178
|
...eventData,
|
|
174
179
|
client_dedup_id: eventId.toString(),
|
|
@@ -176,9 +181,7 @@ var ProvidersSnapchatSdk = (function () {
|
|
|
176
181
|
});
|
|
177
182
|
}
|
|
178
183
|
}
|
|
179
|
-
return
|
|
180
|
-
sdkVersion: "0.25.0" ,
|
|
181
|
-
};
|
|
184
|
+
return result;
|
|
182
185
|
};
|
|
183
186
|
|
|
184
187
|
const data = {
|