From f83a090cfb1ac32f3f6c7e0efd753e8eeeb33508 Mon Sep 17 00:00:00 2001 From: Michael SCHAL Date: Wed, 6 May 2026 11:43:15 +0200 Subject: [PATCH] feat: add article management routes with search, detail, and referential data endpoints --- src/routes/articles.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/routes/articles.js b/src/routes/articles.js index 3087b6a..882df03 100644 --- a/src/routes/articles.js +++ b/src/routes/articles.js @@ -347,7 +347,8 @@ router.get('/:id/photo', async (req, res) => { res.setHeader('Content-Type', imgRes.headers.get('content-type') || 'image/jpeg'); res.setHeader('Cache-Control', 'public, max-age=3600'); - imgRes.body.pipe(res); + const { Readable } = require('stream'); + Readable.fromWeb(imgRes.body).pipe(res); } catch (err) { res.status(500).json({ error: err.message }); }