summaryrefslogtreecommitdiff
path: root/src/app/handler.clj
diff options
context:
space:
mode:
Diffstat (limited to 'src/app/handler.clj')
-rw-r--r--src/app/handler.clj6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/app/handler.clj b/src/app/handler.clj
index fdf722e..21d52ab 100644
--- a/src/app/handler.clj
+++ b/src/app/handler.clj
@@ -12,9 +12,13 @@
(c/GET "/" req (response/content-type (response/resource-response "index.html") "text/html"))
(route/resources "/" {:root ""}))
+(defn state-fn []
+ {:temps @temp/temp
+ :pm (select-keys @pm/pm [:status :current])})
+
(def app
(-> app-routes
- (castra/wrap-castra {:state-fn (fn [] "ohi")} 'app.api)
+ (castra/wrap-castra {:state-fn state-fn} 'app.api)
(d/wrap-defaults d/api-defaults)))
(db/init)