@nsshunt/stsutils 1.16.35 → 1.16.37
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/stsutils.mjs
CHANGED
|
@@ -3426,15 +3426,22 @@ const debugModule = /* @__PURE__ */ getDefaultExportFromCjs(browserExports);
|
|
|
3426
3426
|
class STSWinstonTransport extends Transport {
|
|
3427
3427
|
constructor(opts) {
|
|
3428
3428
|
super(opts);
|
|
3429
|
+
//#debug: debugModule.Debugger;
|
|
3429
3430
|
__privateAdd(this, _debug, void 0);
|
|
3430
|
-
|
|
3431
|
+
__publicField(this, "myopts");
|
|
3432
|
+
this.myopts = opts;
|
|
3431
3433
|
}
|
|
3432
3434
|
log(info, callback) {
|
|
3433
|
-
|
|
3434
|
-
|
|
3435
|
-
|
|
3436
|
-
|
|
3437
|
-
|
|
3435
|
+
setImmediate(() => {
|
|
3436
|
+
if (info[Symbol.for("level")] == "debug") {
|
|
3437
|
+
if (!__privateGet(this, _debug)) {
|
|
3438
|
+
__privateSet(this, _debug, debugModule(`proc:${process.pid}:${this.myopts.stsContext}`));
|
|
3439
|
+
}
|
|
3440
|
+
__privateGet(this, _debug).call(this, info.message);
|
|
3441
|
+
}
|
|
3442
|
+
this.emit("logged", info);
|
|
3443
|
+
callback();
|
|
3444
|
+
});
|
|
3438
3445
|
}
|
|
3439
3446
|
}
|
|
3440
3447
|
_debug = new WeakMap();
|