Permalink
Browse files

Small refactor of keyword-params

  • Loading branch information...
1 parent 621874f commit 5038dc228e4d5eb81809f5f82a33b1b8674ac79e @weavejester weavejester committed Sep 25, 2010
Showing with 3 additions and 5 deletions.
  1. +3 −5 ring-core/src/ring/middleware/keyword_params.clj
View
8 ring-core/src/ring/middleware/keyword_params.clj
@@ -4,11 +4,9 @@
(defn- keyify-params [target]
(cond
(map? target)
- (reduce
- (fn [m [k v]]
- (assoc m (keyword k) (keyify-params v)))
- {}
- target)
+ (into {}
+ (for [[k v] target]
+ [(keyword k) (keyify-params v)]))
(vector? target)
(vec (map keyify-params target))
:else

0 comments on commit 5038dc2

Please sign in to comment.