milkio 0.4.1 → 0.4.2
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.
|
@@ -148,6 +148,13 @@ export function defineHttpHandler(app: MilkioApp, options: ExecuteHttpServerOpti
|
|
|
148
148
|
|
|
149
149
|
const resultsRaw = await app._call(mode, pathstr, params, headers, { executeId, logger, detail });
|
|
150
150
|
|
|
151
|
+
if (resultsRaw.$result.success === false) {
|
|
152
|
+
if (resultsRaw.$result.fail.code === "TYPE_SAFE_ERROR") {
|
|
153
|
+
if (((resultsRaw.$result.fail.data as any).value) === undefined) (resultsRaw.$result.fail.data as any).value === "undefined";
|
|
154
|
+
if (((resultsRaw.$result.fail.data as any).value) === null) (resultsRaw.$result.fail.data as any).value === "null";
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
151
158
|
let fn: any;
|
|
152
159
|
try {
|
|
153
160
|
fn = await schema.apiValidator.validate[pathstr]();
|