diff options
author | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2011-11-15 12:50:04 +0100 |
---|---|---|
committer | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2011-11-15 12:50:04 +0100 |
commit | bbb70dee15c88612ddc35565af6b2b9940357e8d (patch) | |
tree | 6ecdb148ba5548a9b9f3845fc2eed7ea6348673b | |
parent | def6e2d888a2ac2dec16866929ba934c941b2acb (diff) |
Fix Ring middleware setup.
-rw-r--r-- | src/mulk/benki/main.clj | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/mulk/benki/main.clj b/src/mulk/benki/main.clj index 1fba60e..b1afa11 100644 --- a/src/mulk/benki/main.clj +++ b/src/mulk/benki/main.clj @@ -8,10 +8,6 @@ [mulk.benki wiki auth])) -(defonce server (doto (Thread. #(noir.server/start 3001)) - (.setDaemon true) - (.start))) - (defn wrap-utf-8 [handler] (fn [request] (let [response (handler request) @@ -24,7 +20,6 @@ (defn wrap-base-uri [handler] (fn [request] - (prn "Hello!") (let [base-uri "http://localhost:3001"] (with-base-url base-uri ((noir.options/wrap-options handler {:base-url base-uri}) request))))) @@ -33,6 +28,10 @@ (noir.server/add-middleware #(wrap-utf-8 %)) (noir.server/add-middleware #(wrap-base-uri %))) +(defonce server (doto (Thread. #(noir.server/start 3001)) + (.setDaemon true) + (.start))) + (defn -main [& args] (loop [] |