Skip to content
Browse files

Fixed bug that caused intermittent failures when rendering maps

  • Loading branch information...
1 parent 1e2bbcd commit cd0c05683a55f476aca491360c5a8f0f3279d610 @weavejester committed Sep 28, 2010
Showing with 3 additions and 4 deletions.
  1. +3 −4 src/compojure/response.clj
View
7 src/compojure/response.clj
@@ -1,9 +1,8 @@
(ns compojure.response
"Methods for generating Ring response maps"
(:use [ring.util.response :only (response header)])
- (:import java.util.Map
- [java.io File InputStream]
- [clojure.lang IDeref IFn ISeq]))
+ (:import [java.io File InputStream]
+ [clojure.lang APersistentMap IDeref IFn ISeq]))
(defprotocol Renderable
(render [this request]
@@ -19,7 +18,7 @@
(-> (response this)
(header "Content-Type" "text/html"))))
-(extend-type Map
+(extend-type APersistentMap
Renderable
(render [this _]
(merge (response "") this)))

0 comments on commit cd0c056

Please sign in to comment.
Something went wrong with that request. Please try again.