summaryrefslogtreecommitdiffhomepage
path: root/compojure.html.markdown
diff options
context:
space:
mode:
authorMatthias Nehlsen <mn@nehlsen-edv.de>2014-09-12 19:33:03 +0200
committerMatthias Nehlsen <mn@nehlsen-edv.de>2014-09-12 19:33:03 +0200
commitd855f4a156a95fe8eaf8d7946db6aed55ebabf66 (patch)
tree70164bb7013f5de292cfde0206b057b27e23bbbc /compojure.html.markdown
parentdda23f5e803fe503608885eb48a925f6f991df3b (diff)
Update compojure.html.markdown
I think you meant different parameters for title and author
Diffstat (limited to 'compojure.html.markdown')
-rw-r--r--compojure.html.markdown4
1 files changed, 2 insertions, 2 deletions
diff --git a/compojure.html.markdown b/compojure.html.markdown
index 444c8c58..c5b03498 100644
--- a/compojure.html.markdown
+++ b/compojure.html.markdown
@@ -156,7 +156,7 @@ Now, your handlers may utilize query parameters:
(defroutes myapp
(GET "/posts" req
(let [title (get (:params req) "title")
- author (get (:params req) "title")]
+ author (get (:params req) "author")]
(str "Title: " title ", Author: " author))))
```
@@ -166,7 +166,7 @@ Or, for POST and PUT requests, form parameters as well
(defroutes myapp
(POST "/posts" req
(let [title (get (:params req) "title")
- author (get (:params req) "title")]
+ author (get (:params req) "author")]
(str "Title: " title ", Author: " author))))
```