wingbot 3.61.4 → 3.61.5-alpha.1
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/package.json
CHANGED
|
@@ -105,11 +105,19 @@ async function trackingEvent (req, res) {
|
|
|
105
105
|
};
|
|
106
106
|
|
|
107
107
|
try {
|
|
108
|
-
|
|
108
|
+
res.typingOn();
|
|
109
|
+
const result = await fetch(`https://www.google-analytics.com/mp/collect?api_secret=${encodeURIComponent(gaApiSecret)}&measurement_id=${encodeURIComponent(gaMeasurementId)}`, params);
|
|
110
|
+
|
|
111
|
+
// eslint-disable-next-line no-console
|
|
112
|
+
console.log('GA RESPONSE', result.status, body);
|
|
113
|
+
|
|
109
114
|
} catch (e) {
|
|
110
115
|
// eslint-disable-next-line no-console
|
|
111
116
|
console.error('GA FAILED', e, body);
|
|
112
117
|
}
|
|
118
|
+
} else if (clientId) {
|
|
119
|
+
// eslint-disable-next-line no-console
|
|
120
|
+
console.error('GA MISSING', req.configuration);
|
|
113
121
|
}
|
|
114
122
|
|
|
115
123
|
res.trackEvent(type || 'report', c, a, l, v);
|