diff options
Diffstat (limited to 'server/controllers')
-rw-r--r-- | server/controllers/static.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/controllers/static.ts b/server/controllers/static.ts index f10427f3e..3ccf624a7 100644 --- a/server/controllers/static.ts +++ b/server/controllers/static.ts | |||
@@ -48,13 +48,13 @@ staticRouter.use( | |||
48 | const thumbnailsPhysicalPath = CONFIG.STORAGE.THUMBNAILS_DIR | 48 | const thumbnailsPhysicalPath = CONFIG.STORAGE.THUMBNAILS_DIR |
49 | staticRouter.use( | 49 | staticRouter.use( |
50 | STATIC_PATHS.THUMBNAILS, | 50 | STATIC_PATHS.THUMBNAILS, |
51 | express.static(thumbnailsPhysicalPath, { maxAge: STATIC_MAX_AGE }) | 51 | express.static(thumbnailsPhysicalPath, { maxAge: STATIC_MAX_AGE, fallthrough: false }) // 404 if the file does not exist |
52 | ) | 52 | ) |
53 | 53 | ||
54 | const avatarsPhysicalPath = CONFIG.STORAGE.AVATARS_DIR | 54 | const avatarsPhysicalPath = CONFIG.STORAGE.AVATARS_DIR |
55 | staticRouter.use( | 55 | staticRouter.use( |
56 | STATIC_PATHS.AVATARS, | 56 | STATIC_PATHS.AVATARS, |
57 | express.static(avatarsPhysicalPath, { maxAge: STATIC_MAX_AGE }) | 57 | express.static(avatarsPhysicalPath, { maxAge: STATIC_MAX_AGE, fallthrough: false }) // 404 if the file does not exist |
58 | ) | 58 | ) |
59 | 59 | ||
60 | // We don't have video previews, fetch them from the origin instance | 60 | // We don't have video previews, fetch them from the origin instance |