Update index.js
This commit is contained in:
@@ -35,8 +35,8 @@ const upload = multer({ storage: storage });
|
||||
|
||||
app.use(cors());
|
||||
app.use(express.json());
|
||||
// Serve uploaded files statically
|
||||
app.use('/uploads', express.static(uploadDir));
|
||||
// Serve uploaded files statically at /api/uploads to match the frontend request path passed via Nginx
|
||||
app.use('/api/uploads', express.static(uploadDir));
|
||||
|
||||
// --- HELPER FUNCTIONS ---
|
||||
const safeJsonParse = (val, fallback) => {
|
||||
|
||||
Reference in New Issue
Block a user