Skip to content

Commit fc1a99a

Browse files
author
Brijesh
committed
Minio logging
1 parent 437f2f9 commit fc1a99a

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Diff for: src/router/routes_v1/files.js

+6-6
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,11 @@ router.get('/upload-url', asyncMiddleware(async (req, res) => {
5959
}
6060

6161
const url = await client.presignedPutObject(bucket, req.query.name);
62-
63-
const publicUrl = publicEndPoint
64-
? url.replace(endPoint, publicEndPoint)
65-
: url;
66-
62+
console.error(`URL ${url}`);
63+
const publicUrl = publicEndPoint ? url.replace(endPoint, publicEndPoint) : url;
64+
console.error(`public URL ${publicUrl}`);
65+
console.log(process.env.NODE_ENV);
66+
console.log(process.env.NODE_ENV === 'production' ? cleanProductionURL(publicUrl) : publicUrl);
6767
res.json({
6868
url: process.env.NODE_ENV === 'production' ? cleanProductionURL(publicUrl) : publicUrl,
6969
});
@@ -113,4 +113,4 @@ router.get('/download-url', asyncMiddleware(async (req, res) => {
113113
});
114114
}));
115115

116-
export default router;
116+
export default router;

0 commit comments

Comments
 (0)