From 457dd1d34665cd474f4a7ec3c88030411cd44326 Mon Sep 17 00:00:00 2001 From: Arya <90748009+aryamohanan@users.noreply.github.com> Date: Mon, 18 Mar 2024 14:17:01 +0530 Subject: [PATCH] test: fixed esm test for mongo (#1077) --- packages/collector/test/tracing/database/mongodb/app.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/collector/test/tracing/database/mongodb/app.mjs b/packages/collector/test/tracing/database/mongodb/app.mjs index c8f2833cf2..66c5b48c14 100644 --- a/packages/collector/test/tracing/database/mongodb/app.mjs +++ b/packages/collector/test/tracing/database/mongodb/app.mjs @@ -230,7 +230,7 @@ app.post('/long-find', (req, res) => { // Execute another traced call to verify that we keep the tracing context. return fetch(`http://127.0.0.1:${agentPort}?call=${call}`); }) - .then(() => res.json(mongoResponse)) + .then(() => res.json(mongoResponse || {})) .catch(e => { log('Failed to find document', e); res.sendStatus(500);