From fae0940f3a683f3d8b880a74b90248a4cbd83387 Mon Sep 17 00:00:00 2001 From: gered Date: Fri, 7 Jun 2013 20:14:08 -0400 Subject: [PATCH] do a proper redirect if a file cannot be served up --- src/blarg/routes/files.clj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/blarg/routes/files.clj b/src/blarg/routes/files.clj index bfdf0fd..8a68b5b 100644 --- a/src/blarg/routes/files.clj +++ b/src/blarg/routes/files.clj @@ -66,7 +66,7 @@ (defn get-file [path] (if-let [file (files/get-file path (auth/logged-in?))] (resp/content-type (:content_type file) (:data file)) - (resp/status 404 nil))) + (resp/redirect "/notfound"))) (defroutes files-routes (restricted GET "/listfiles" [] (list-files "/"))