@nsshunt/stsfhirclient 2.0.39 → 2.0.41

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.
@@ -9973,7 +9973,7 @@ var FhirRESTClient = class {
9973
9973
  };
9974
9974
  };
9975
9975
  //#endregion
9976
- //#region node_modules/@nsshunt/stssocketioutils/dist/tiny-emitter-DcZ69ZvJ.js
9976
+ //#region node_modules/@nsshunt/stssocketioutils/dist/tiny-emitter-Ci1ma0VV.js
9977
9977
  var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
9978
9978
  var require_tiny_emitter = /* @__PURE__ */ __commonJSMin(((exports, module) => {
9979
9979
  function E() {}
@@ -10600,8 +10600,8 @@ var BaseXHR = class extends Polling {
10600
10600
  /**
10601
10601
  * Sends data.
10602
10602
  *
10603
- * @param {String} data to send.
10604
- * @param {Function} called upon flush.
10603
+ * @param {String} data - data to send.
10604
+ * @param {Function} fn - called upon flush.
10605
10605
  * @private
10606
10606
  */
10607
10607
  doWrite(data, fn) {
@@ -11332,7 +11332,7 @@ var SocketWithoutUpgrade = class SocketWithoutUpgrade extends _socket_io_compone
11332
11332
  /**
11333
11333
  * Sends a packet.
11334
11334
  *
11335
- * @param {String} type: packet type.
11335
+ * @param {String} type - packet type.
11336
11336
  * @param {String} data.
11337
11337
  * @param {Object} options.
11338
11338
  * @param {Function} fn - callback function.
@@ -13388,6 +13388,9 @@ var FhirSocketClient = class extends SocketIoClient {
13388
13388
  this.options = options;
13389
13389
  this.SetupWSSClient();
13390
13390
  }
13391
+ LogDebugMessage(message) {
13392
+ if (this.options.verboseLogging === true) super.LogDebugMessage(message);
13393
+ }
13391
13394
  SocketConnect(socket) {
13392
13395
  this.LogDebugMessage(chalk.green(`FhirSocketClient:SocketConnect(): ID: [${this.id}] clientName: [${this.name}]: --> connected`));
13393
13396
  if (this.options.joinRooms.length > 0 && socket) socket.emit("__STSjoinRoom", this.options.joinRooms);
@@ -13444,11 +13447,11 @@ var FhirSocketClient = class extends SocketIoClient {
13444
13447
  return true;
13445
13448
  }
13446
13449
  if (attempts === resetAfterAttempts) {
13447
- this.LogDebugMessage(chalk.rgb(255, 165, 0)(`FhirSocketClient:WaitForSocketConnected(): ID: [${this.id}] clientName: [${this.name}] Resetting Socket. Attempt Number: [${attempts}]`));
13450
+ this.LogWarningMessage(chalk.rgb(255, 165, 0)(`FhirSocketClient:WaitForSocketConnected(): ID: [${this.id}] clientName: [${this.name}] Resetting Socket. Attempt Number: [${attempts}]`));
13448
13451
  this.ResetSocket();
13449
- this.LogDebugMessage(chalk.rgb(255, 165, 0)(`FhirSocketClient:WaitForSocketConnected(): ID: [${this.id}] clientName: [${this.name}] Socket Reset. Attempt Number: [${attempts}]`));
13452
+ this.LogWarningMessage(chalk.rgb(255, 165, 0)(`FhirSocketClient:WaitForSocketConnected(): ID: [${this.id}] clientName: [${this.name}] Socket Reset. Attempt Number: [${attempts}]`));
13450
13453
  await (0, _nsshunt_stsutils.Sleep)(retryDelay);
13451
- this.LogDebugMessage(chalk.rgb(255, 165, 0)(`FhirSocketClient:WaitForSocketConnected(): ID: [${this.id}] clientName: [${this.name}] SetupSocket. Attempt Number: [${attempts}]`));
13454
+ this.LogWarningMessage(chalk.rgb(255, 165, 0)(`FhirSocketClient:WaitForSocketConnected(): ID: [${this.id}] clientName: [${this.name}] SetupSocket. Attempt Number: [${attempts}]`));
13452
13455
  this.SetupSocket();
13453
13456
  await (0, _nsshunt_stsutils.Sleep)(retryDelay);
13454
13457
  }