mirror of
https://github.com/typicode/json-server.git
synced 2025-07-28 20:52:08 +08:00
Fix
This commit is contained in:
@ -38,7 +38,6 @@ function createApp(db, options) {
|
|||||||
|
|
||||||
// Use default or user public directory
|
// Use default or user public directory
|
||||||
// Note: should be done before CORS and app.router setting
|
// Note: should be done before CORS and app.router setting
|
||||||
console.log(fs.existsSync(process.cwd() + '/public'), process.cwd() + '/public')
|
|
||||||
if (fs.existsSync(process.cwd() + '/public')) {
|
if (fs.existsSync(process.cwd() + '/public')) {
|
||||||
app.use(express.static(process.cwd() + '/public'));
|
app.use(express.static(process.cwd() + '/public'));
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user