diff options
author | Amine Mouafik <amine@mouafik.fr> | 2019-11-29 16:51:45 +0700 |
---|---|---|
committer | Amine Mouafik <amine@mouafik.fr> | 2019-11-29 16:51:45 +0700 |
commit | 36ccd2fd3c3b53ca5d269314282579cf01acb907 (patch) | |
tree | ec6e1cc5ddb0f099b21fa509c975f37045f92f7b /app | |
parent | #15 Setup Sentry to capture errors (diff) | |
download | ferdium-server-36ccd2fd3c3b53ca5d269314282579cf01acb907.tar.gz ferdium-server-36ccd2fd3c3b53ca5d269314282579cf01acb907.tar.zst ferdium-server-36ccd2fd3c3b53ca5d269314282579cf01acb907.zip |
#17 Return HTTP 404 when no announcements available
Diffstat (limited to 'app')
-rw-r--r-- | app/Controllers/Http/StaticController.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/Controllers/Http/StaticController.js b/app/Controllers/Http/StaticController.js index 2e424e1..5b8d716 100644 --- a/app/Controllers/Http/StaticController.js +++ b/app/Controllers/Http/StaticController.js | |||
@@ -234,7 +234,7 @@ class StaticController { | |||
234 | if (await fs.pathExists(announcement)) { | 234 | if (await fs.pathExists(announcement)) { |
235 | return response.download(announcement); | 235 | return response.download(announcement); |
236 | } | 236 | } |
237 | return response.send('No announcement found.'); | 237 | return response.status(404).send('No announcement found.'); |
238 | } | 238 | } |
239 | } | 239 | } |
240 | 240 | ||