You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(clj-http.client/post"http://localhost" {:multipart [{:name"number":content1}]})
;; => IllegalArgumentException Body may not be null org.apache.http.util.Args.notNull (Args.java:54)
In clj-http.mutipart.create-multipart-entity, the type of (:content {:name "number" :content 1}) does not match any predicates in the cond clause, so part is bound to nil, which leads to the opaque error "Body may not be null."
Is there a reason why there isn't an else clause where things that aren't strings/streams/files/byte-arrays are stringified and treated as strings? At least, a clearer error would be helpful.
The text was updated successfully, but these errors were encountered:
Multipart params cannot be numbers:
In
clj-http.mutipart.create-multipart-entity
, the type of(:content {:name "number" :content 1})
does not match any predicates in thecond
clause, sopart
is bound tonil
, which leads to the opaque error "Body may not be null."Is there a reason why there isn't an
else
clause where things that aren't strings/streams/files/byte-arrays are stringified and treated as strings? At least, a clearer error would be helpful.The text was updated successfully, but these errors were encountered: