aboutsummaryrefslogtreecommitdiff
path: root/config.ru
diff options
context:
space:
mode:
authorBrandon Mathis <brandon@imathis.com>2013-04-09 16:37:48 -0500
committerBrandon Mathis <brandon@imathis.com>2013-04-09 16:37:48 -0500
commit09558c64e6fb4fd406baa379ef79d9419b0a6e03 (patch)
treedb2838c2bffb5b3ccd79e622cb7d3113da8484e8 /config.ru
parent1bd2b62a80f3a7be330cb9600a2206a678e6863d (diff)
downloadmy_new_personal_website-09558c64e6fb4fd406baa379ef79d9419b0a6e03.tar.xz
my_new_personal_website-09558c64e6fb4fd406baa379ef79d9419b0a6e03.zip
Sinatra now correctly returns code 404 when a page is not found. Closes #1198
Diffstat (limited to '')
-rw-r--r--config.ru2
1 files changed, 1 insertions, 1 deletions
diff --git a/config.ru b/config.ru
index fddabac2..8e3dc08a 100644
--- a/config.ru
+++ b/config.ru
@@ -11,7 +11,7 @@ class SinatraStaticServer < Sinatra::Base
end
not_found do
- send_sinatra_file('404.html') {"Sorry, I cannot find #{request.path}"}
+ send_file(File.join(File.dirname(__FILE__), 'public', '404.html'), {:status => 404})
end
def send_sinatra_file(path, &missing_file_block)