From a57cb49c2b961e1594d9a41668d7d9a14595315a Mon Sep 17 00:00:00 2001 From: Thel Seraphim Date: Fri, 13 Mar 2015 21:17:01 -0700 Subject: [PATCH] re-order routes to prevent 404 on loading css --- src/pronouns/web.clj | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/pronouns/web.clj b/src/pronouns/web.clj index 2189038..646e142 100644 --- a/src/pronouns/web.clj +++ b/src/pronouns/web.clj @@ -23,16 +23,17 @@ :headers {"Content-Type" "text/plain"} :body (pages/front)}) + (GET "/pronouns.css" {params :params} + {:status 200 + :headers {"Content-Type" "text/css"} + :body (slurp (io/resource "pronouns.css"))}) + + (GET "/*" {params :params} {:status 200 :headers {"Content-Type" "text/html"} :body (pages/pronouns (:* params) pronouns-table)}) - (GET "/pronouns.css" {params :params} - {:status 200 - :headers {"Content-Type" "text/css"} - :body (slurp (io/resource "pronouns.css"))}) - (ANY "*" [] (route/not-found (slurp (io/resource "404.html")))))