@mhubcloud/tms_core 3.2.0-beta.0 → 3.2.0-beta.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/dist/index.js CHANGED
@@ -267,6 +267,9 @@ function parseErrorMessage(error) {
267
267
 
268
268
  // src/defaultPublisher.ts
269
269
  async function defaultPublisher(azureFunctionContext, serviceBusMessage, source, platformPublisher, trigger) {
270
+ if (serviceBusMessage.$schema === "mhub/pingtest") {
271
+ return;
272
+ }
270
273
  const processMessagePromises = [];
271
274
  processMessagePromises.push(
272
275
  processMessage(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mhubcloud/tms_core",
3
- "version": "3.2.0-beta.0",
3
+ "version": "3.2.0-beta.1",
4
4
  "description": "Core function for mHub Cloud TMS publishers",
5
5
  "homepage": "https://mhubcloud.com/",
6
6
  "license": "Apache 2.0",
@@ -11,7 +11,7 @@ import * as utils from './utils/utils';
11
11
  * Implements the Azure Function, called for set of events received via Event Hub
12
12
  * @deprecated Udelat novou metodu, ktera bude spravne a bude inicializovat classu
13
13
  * @param azureFunctionContext Azure Function Context
14
- * @param serviceBusMessage Array of messages received from Event Hub
14
+ * @param serviceBusMessage Message received from Service Bus
15
15
  * @param source Name of the publisher (name of the folder in which it is implemented)
16
16
  * @param platformPublisher Publisher implementation instance (from <publisher>/publisher.js)
17
17
  * @param trigger
@@ -23,6 +23,9 @@ export async function defaultPublisher(
23
23
  platformPublisher: PlatformPublisher,
24
24
  trigger: (a: unknown) => EventPublisher[],
25
25
  ) {
26
+ if (serviceBusMessage.$schema === 'mhub/pingtest') {
27
+ return;
28
+ }
26
29
  const processMessagePromises = [];
27
30
  processMessagePromises.push(
28
31
  processMessage(
@@ -31,7 +31,7 @@ describe('test UniversalAnalytics publisher', function () {
31
31
  tm: 'GTM-N7K9L4X',
32
32
  tmv: '494',
33
33
  },
34
- $schema: '/mhub/pageview',
34
+ $schema: 'mhub/pageview',
35
35
  enqueuedAt: 1657003409370,
36
36
  ads: [],
37
37
  };