c2-http 1.0.169 → 1.0.170
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.
|
@@ -8,11 +8,11 @@ const c2_util_1 = require("c2-util");
|
|
|
8
8
|
// import moment from "moment";
|
|
9
9
|
class MiddlewareBody {
|
|
10
10
|
config(expressApplication) {
|
|
11
|
-
expressApplication.use(body_parser_1.default.json({ limit: "
|
|
12
|
-
expressApplication.use(body_parser_1.default.urlencoded({ limit: "
|
|
13
|
-
expressApplication.use(body_parser_1.default.text({ limit: "
|
|
11
|
+
expressApplication.use(body_parser_1.default.json({ limit: "1mb" }));
|
|
12
|
+
expressApplication.use(body_parser_1.default.urlencoded({ limit: "1mb", extended: true })); // Aumentar de 5mb para 25mb
|
|
13
|
+
expressApplication.use(body_parser_1.default.text({ limit: "1mb" }));
|
|
14
14
|
// Adicionar parser para tipos não especificados
|
|
15
|
-
expressApplication.use(body_parser_1.default.raw({ limit: "
|
|
15
|
+
expressApplication.use(body_parser_1.default.raw({ limit: "1mb", type: "*/*" }));
|
|
16
16
|
expressApplication.use((request, response, next) => {
|
|
17
17
|
// log("LOG_BODY", "Body middleware enabled")
|
|
18
18
|
const str = JSON.stringify(request.body);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "c2-http",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.170",
|
|
4
4
|
"description": "Biblioteca Typescript para API NodeJS",
|
|
5
5
|
"repository": "https://cabralsilva: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@github.com/cabralsilva/c2-http.git",
|
|
6
6
|
"author": "Daniel Cabral <cabralconsultoriaemsoftware@gmail.com>",
|