We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 94a4647 + aa03f40 commit 2941cd9Copy full SHA for 2941cd9
2 files changed
src/ring/util/codec.clj
@@ -98,7 +98,9 @@
98
(str/join "&"))))
99
Object
100
(form-encode* [x encoding]
101
- (form-encode* (str x) encoding)))
+ (form-encode* (str x) encoding))
102
+ nil
103
+ (form-encode* [x encoding] ""))
104
105
(defn form-encode
106
"Encode the supplied value into www-form-urlencoded format, often used in
test/ring/util/test/codec.clj
@@ -42,6 +42,7 @@
42
{"a" "b"} "a=b"
43
{:a "b"} "a=b"
44
{"a" 1} "a=1"
45
+ {"a" nil} "a="
46
{"a" "b" "c" "d"} "a=b&c=d"
47
{"a" "b c"} "a=b+c")
48
(is (= (form-encode {"a" "foo/bar"} "UTF-16") "a=foo%FE%FF%00%2Fbar"))))
0 commit comments