Skip to content

Commit 23be1df

Browse files
committed
fix: decode file path in GCS proxy endpoint to handle special characters
1 parent d37946e commit 23be1df

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ const handleRequest = async (req, res) => {
147147
await listVersions(req, res);
148148
} else if (pathname.startsWith('/v1/static/') && req.method === 'GET') {
149149
// GCS proxy endpoint for reports files
150-
const filePath = pathname.replace('/v1/static/', '');
150+
const filePath = decodeURIComponent(pathname.replace('/v1/static/', ''));
151151
if (!filePath) {
152152
res.statusCode = 400;
153153
res.end(JSON.stringify({ error: 'File path required' }));

0 commit comments

Comments
 (0)