@tahminator/sapling 2.0.2-beta.62de85fd → 2.0.2-beta.a1b9edd3
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 +5 -13
- package/dist/index.mjs +5 -13
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -695,20 +695,12 @@ Split these into separate @MiddlewareClass classes, or merge the logic into a si
|
|
|
695
695
|
if (schemas.body) request.body = await _parseOrThrow(schemas.body, request.body, "reqbody");
|
|
696
696
|
if (schemas.param) request.params = await _parseOrThrow(schemas.param, request.params, "reqparams");
|
|
697
697
|
if (schemas.query) {
|
|
698
|
-
console.log("schemas.query exists");
|
|
699
|
-
console.log("schemas.query exists as " + JSON.stringify(schemas.query));
|
|
700
698
|
const parsedQuery = await _parseOrThrow(schemas.query, request.query, "reqquery");
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
configurable: true
|
|
707
|
-
});
|
|
708
|
-
} catch {
|
|
709
|
-
request.query = parsedQuery;
|
|
710
|
-
}
|
|
711
|
-
console.log("request.query rewritten, now is", { query: JSON.stringify(request.query) });
|
|
699
|
+
Object.defineProperty(request, "query", {
|
|
700
|
+
value: parsedQuery,
|
|
701
|
+
writable: true,
|
|
702
|
+
configurable: true
|
|
703
|
+
});
|
|
712
704
|
}
|
|
713
705
|
}
|
|
714
706
|
const result = await fn.bind(controllerInstance)(request, response, next);
|
package/dist/index.mjs
CHANGED
|
@@ -671,20 +671,12 @@ Split these into separate @MiddlewareClass classes, or merge the logic into a si
|
|
|
671
671
|
if (schemas.body) request.body = await _parseOrThrow(schemas.body, request.body, "reqbody");
|
|
672
672
|
if (schemas.param) request.params = await _parseOrThrow(schemas.param, request.params, "reqparams");
|
|
673
673
|
if (schemas.query) {
|
|
674
|
-
console.log("schemas.query exists");
|
|
675
|
-
console.log("schemas.query exists as " + JSON.stringify(schemas.query));
|
|
676
674
|
const parsedQuery = await _parseOrThrow(schemas.query, request.query, "reqquery");
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
configurable: true
|
|
683
|
-
});
|
|
684
|
-
} catch {
|
|
685
|
-
request.query = parsedQuery;
|
|
686
|
-
}
|
|
687
|
-
console.log("request.query rewritten, now is", { query: JSON.stringify(request.query) });
|
|
675
|
+
Object.defineProperty(request, "query", {
|
|
676
|
+
value: parsedQuery,
|
|
677
|
+
writable: true,
|
|
678
|
+
configurable: true
|
|
679
|
+
});
|
|
688
680
|
}
|
|
689
681
|
}
|
|
690
682
|
const result = await fn.bind(controllerInstance)(request, response, next);
|