@shushed/helpers 0.0.139 → 0.0.140
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 +11 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -171312,7 +171312,15 @@ var ActionHelper = class _ActionHelper {
|
|
|
171312
171312
|
throw new Error("Invariant. preOnExecute must be called first");
|
|
171313
171313
|
}
|
|
171314
171314
|
const allowProductionTopic = this.config.allowProductionTopic;
|
|
171315
|
-
|
|
171315
|
+
let prefix = "";
|
|
171316
|
+
let suffix = "";
|
|
171317
|
+
if (this.config.topicName.indexOf("---") === -1 && this.runtime.envName !== "prod" && !allowProductionTopic) {
|
|
171318
|
+
prefix = `${this.runtime.envName}---`;
|
|
171319
|
+
}
|
|
171320
|
+
if (internal) {
|
|
171321
|
+
suffix = "-internal";
|
|
171322
|
+
}
|
|
171323
|
+
return [prefix, this.config.topicName, suffix].join("");
|
|
171316
171324
|
}
|
|
171317
171325
|
getRuntime() {
|
|
171318
171326
|
if (!this.opts) {
|
|
@@ -171571,7 +171579,7 @@ var TriggerHelper = class {
|
|
|
171571
171579
|
if (!apiKeyIsValid && (action.actionOptions.routingConditions || {}).api?.havingApiKey) {
|
|
171572
171580
|
return optionsEnchanced.req.throw(401, `Invalid Authorization Header`);
|
|
171573
171581
|
}
|
|
171574
|
-
options.logging.log("Action matched preparing to execute - ", action.actionOptions);
|
|
171582
|
+
options.logging.log("Action matched preparing to execute - ", action.actionOptions.routingConditions);
|
|
171575
171583
|
try {
|
|
171576
171584
|
await action.onExecute(config, optionsEnchanced, message);
|
|
171577
171585
|
} catch (error) {
|
|
@@ -171584,7 +171592,7 @@ var TriggerHelper = class {
|
|
|
171584
171592
|
}
|
|
171585
171593
|
if (executionFinished) {
|
|
171586
171594
|
if (terminateResult) {
|
|
171587
|
-
options.logging.log("Trigger finished without triggering the rest of workflow",
|
|
171595
|
+
options.logging.log("Trigger finished without triggering the rest of workflow", terminateResult);
|
|
171588
171596
|
}
|
|
171589
171597
|
return;
|
|
171590
171598
|
}
|