Browse files

Only use GET for count requests that do not have body (the query part)

  • Loading branch information...
1 parent d2d2f0f commit ff5c154721a8fc05445f60b8dd7d82360293e9ba @michaelklishin michaelklishin committed Oct 18, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/clojurewerkz/elastisch/rest/document.clj
@@ -106,9 +106,9 @@
([index mapping-type]
(rest/get (rest/count-url) (join-names index) (join-names mapping-type)))
([index mapping-type query]
- (rest/get (rest/count-url) (join-names index) (join-names mapping-type) :body query))
+ (rest/post (rest/count-url) (join-names index) (join-names mapping-type) :body query))
([index mapping-type query & { :as options }]
- (rest/get (rest/count-url (join-names index) (join-names mapping-type))
+ (rest/post (rest/count-url (join-names index) (join-names mapping-type))
:query-params (select-keys options [:df :analyzer :default_operator])
:body query)))

0 comments on commit ff5c154

Please sign in to comment.