Skip to content

Commit

Permalink
Allow non-strict JSON
Browse files Browse the repository at this point in the history
  • Loading branch information
dguenther committed Sep 19, 2024
1 parent 5eb8542 commit 8aaed07
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@ if (process.env["UPLOAD_BLOCKS"] === "true") {
}

export const app = express();
app.use(bodyParser.json());
app.use(
bodyParser.json({
// Allows parsing of JSON-encoded strings, as opposed to just arrays/objects
strict: false,
}),
);

// Register tsoa routes
RegisterRoutes(app);
Expand Down

0 comments on commit 8aaed07

Please sign in to comment.