 (defn string
   "Converts response to string."
   [resp]
-  ;; TODO remove instance? check once refactoring is complete and
-  ;; response is unified
   (let [enc (or (get-encoding (headers resp)) duck/*default-encoding*)
-        body  (body resp)
+        body (body resp)
         convert (fn [#^ByteArrayOutputStream baos] (.toString baos enc))]
     (if (seq? body)
       (map convert body)

  {:author "Hubert Iwaniuk"}
  (:require [clojure.contrib.io :as duck])
  (:use async.http.client.request
        async.http.client.headers)
  (:import (java.io ByteArrayOutputStream)
           (com.ning.http.client AsyncHttpClient AsyncHttpClientConfig$Builder)))


     (binding [*ahc* c#]
       ~@body)))

(do-template
 [fn-name method]
 (defn fn-name
   [#^String url & {:as options}]
   (apply execute-request
          (apply prepare-request method url (apply concat options))
          (apply concat *default-callbacks*)))
 GET :get
 POST :post
 PUT :put
 DELETE :delete
 HEAD :head
 OPTIONS :options)

(defn request-stream
  "Consumes stream from given url.
