Skip to content

Commit 9fd5739

Browse files
authored
Merge pull request #536 from ruroru/master
Fix reflection in core protocols
2 parents 3cfd4a2 + feb353c commit 9fd5739

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ring-core-protocols/src/ring/core/protocols.clj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
(some #(when (.equalsIgnoreCase "content-type" (key %)) (val %)))
3232
(find-charset-in-content-type)))
3333

34-
(defn- str->bytes [^String s ^String charset]
34+
(defn- str->bytes ^bytes [^String s ^String charset]
3535
(if charset (.getBytes s charset) (.getBytes s)))
3636

3737
(defn- response-writer ^Writer [response ^OutputStream output-stream]
@@ -54,7 +54,7 @@
5454

5555
(extend-protocol StreamableResponseBody
5656
String
57-
(write-body-to-stream [body response output-stream]
57+
(write-body-to-stream [body response ^OutputStream output-stream]
5858
;; No need to use a writer for a single string, and this prevents a
5959
;; flush being used for a value of fixed length.
6060
(.write output-stream (str->bytes body (response-charset response)))

0 commit comments

Comments
 (0)