From 70e9ad82051c84b3a23cbd4158caa0ec0b27cb09 Mon Sep 17 00:00:00 2001 From: Tim Fish Date: Tue, 29 Oct 2024 20:33:23 +0100 Subject: [PATCH] simplify usage --- .../node-integration-tests/suites/reporting-api/server.mjs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/dev-packages/node-integration-tests/suites/reporting-api/server.mjs b/dev-packages/node-integration-tests/suites/reporting-api/server.mjs index c59d18022135..8359ac00fafd 100644 --- a/dev-packages/node-integration-tests/suites/reporting-api/server.mjs +++ b/dev-packages/node-integration-tests/suites/reporting-api/server.mjs @@ -12,9 +12,7 @@ import express from 'express'; const app = express(); -app.use(express.json({ type: 'application/reports+json' })); - -app.post('/reporting-api', async (req, res) => { +app.post('/reporting-api', express.json({ type: 'application/reports+json' }), async (req, res) => { await captureReportingApi(req.body); res.sendStatus(200); });