@shushed/helpers 0.0.233 → 0.0.234
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.
|
@@ -777,9 +777,6 @@ class EnvEngine extends runtime_1.default {
|
|
|
777
777
|
projectId: pubSubProjectId
|
|
778
778
|
});
|
|
779
779
|
global.HUSH_PUBSUB_INSTANCE = pubSub;
|
|
780
|
-
this.logging.log('getPubSubHelper', {
|
|
781
|
-
serviceAccountEmail: serviceAccount,
|
|
782
|
-
});
|
|
783
780
|
return new pubsub_1.default(this, {
|
|
784
781
|
serviceAccountEmail: serviceAccount
|
|
785
782
|
}, pubSub);
|
|
@@ -98,7 +98,7 @@ class Runtime {
|
|
|
98
98
|
if (opts.trigger?.label) {
|
|
99
99
|
this.triggerId = opts.trigger.id || '00000000-0000-0000-0000-000000000000';
|
|
100
100
|
this.triggerName = opts.trigger?.label?.split(/\sv\d/)[0]?.trim() || this.workflowId;
|
|
101
|
-
this.triggerVersion = buildSemver((opts.trigger
|
|
101
|
+
this.triggerVersion = buildSemver((opts.trigger?.label?.split(/\sv/)?.find(x => /^\d/.test(x))?.trim() || '0'));
|
|
102
102
|
this.triggerDataProperties = opts.trigger.data?.properties;
|
|
103
103
|
this.triggerConfigProperties = opts.trigger.config?.properties;
|
|
104
104
|
}
|
|
@@ -182,7 +182,7 @@ class Runtime {
|
|
|
182
182
|
exports.default = Runtime;
|
|
183
183
|
;
|
|
184
184
|
function buildSemver(version) {
|
|
185
|
-
const parts = version.split(
|
|
185
|
+
const parts = version.split('.').map(x => parseInt(x, 10)).filter(x => !isNaN(x));
|
|
186
186
|
for (let i = parts.length; i < 3; i++) {
|
|
187
187
|
parts.push(0);
|
|
188
188
|
}
|