File tree 1 file changed +5
-4
lines changed
1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -655,7 +655,8 @@ decode-result: func[
655
655
][
656
656
unless code-page [code-page: "utf-8" ]
657
657
sys/log/info 'HTTP ["Trying to decode from code-page:^[ [m" code-page]
658
- try [result/2: iconv result/2 code-page]
658
+ ; using also deline to normalize possible CRLF to LF
659
+ try [result/2: deline iconv result/2 code-page]
659
660
]
660
661
result
661
662
]
@@ -703,12 +704,12 @@ sys/make-scheme [
703
704
sys/log/debug 'HTTP "WRITE"
704
705
;?? port
705
706
case [
706
- map? value [
707
- value: reduce [[Content-Type: "application/json; charset=utf-8" ] encode 'JSON value]
708
- ]
709
707
binary? value [
710
708
value: reduce [[Content-Type: "application/octet-stream" ] value]
711
709
]
710
+ map? value [
711
+ value: reduce [[Content-Type: "application/json; charset=utf-8" ] encode 'JSON value]
712
+ ]
712
713
not block? value [
713
714
value: reduce [[Content-Type: "application/x-www-form-urlencoded; charset=utf-8" ] form value]
714
715
]
You can’t perform that action at this time.
0 commit comments