@teamkeel/functions-runtime 0.416.1 → 0.417.0
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.cjs +7 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +42 -17
- package/dist/index.d.ts +42 -17
- package/dist/index.js +7 -4
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2335,9 +2335,11 @@ var import_json_rpc_26 = require("json-rpc-2.0");
|
|
|
2335
2335
|
var opentelemetry6 = __toESM(require("@opentelemetry/api"), 1);
|
|
2336
2336
|
|
|
2337
2337
|
// src/tryExecuteFlow.js
|
|
2338
|
-
function tryExecuteFlow(db, cb) {
|
|
2338
|
+
function tryExecuteFlow(db, request, cb) {
|
|
2339
2339
|
return withDatabase(db, false, async () => {
|
|
2340
|
-
return
|
|
2340
|
+
return withAuditContext(request, async () => {
|
|
2341
|
+
return cb();
|
|
2342
|
+
});
|
|
2341
2343
|
});
|
|
2342
2344
|
}
|
|
2343
2345
|
__name(tryExecuteFlow, "tryExecuteFlow");
|
|
@@ -3183,7 +3185,8 @@ async function complete(options) {
|
|
|
3183
3185
|
title: options.title,
|
|
3184
3186
|
description: options.description,
|
|
3185
3187
|
content: contentUiConfig || [],
|
|
3186
|
-
autoClose: options.autoClose
|
|
3188
|
+
autoClose: options.autoClose,
|
|
3189
|
+
allowRestart: typeof options.allowRestart === "boolean" ? options.allowRestart ? { inputs: void 0 } : void 0 : options.allowRestart
|
|
3187
3190
|
};
|
|
3188
3191
|
}
|
|
3189
3192
|
__name(complete, "complete");
|
|
@@ -3247,7 +3250,7 @@ async function handleFlow(request, config) {
|
|
|
3247
3250
|
const inputs = parseInputs(request.meta?.inputs);
|
|
3248
3251
|
let response = void 0;
|
|
3249
3252
|
try {
|
|
3250
|
-
response = await tryExecuteFlow(db, async () => {
|
|
3253
|
+
response = await tryExecuteFlow(db, request, async () => {
|
|
3251
3254
|
return flowFunction(ctx, inputs);
|
|
3252
3255
|
});
|
|
3253
3256
|
} catch (e) {
|