From 8e830fe4b5f0dc34d243763a9bdf36f2cde40aa7 Mon Sep 17 00:00:00 2001 From: williamlardier Date: Thu, 24 Oct 2024 09:58:09 +0200 Subject: [PATCH] End logger in Put route Issue: ARSN-441 --- lib/s3routes/routes/routePUT.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/s3routes/routes/routePUT.ts b/lib/s3routes/routes/routePUT.ts index c7d94ca75..c57d65a08 100644 --- a/lib/s3routes/routes/routePUT.ts +++ b/lib/s3routes/routes/routePUT.ts @@ -225,7 +225,8 @@ export default function routePUT( return routesUtils.responseNoBody(errors.BadRequest, null, response, 400, log); } - log.addDefaultFields({ contentLength: parsedContentLength }); + // @ts-expect-error werelogs types are not up to date + log.end().addDefaultFields({ contentLength: parsedContentLength }); api.callApiMethod('objectPut', request, response, log, (err, resHeaders) => { routesUtils.statsReport500(err, statsClient);