File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -570,9 +570,9 @@ def encode_content(headers, body)
570
570
content_type = headers [ "content-type" ]
571
571
case [ content_type , body ]
572
572
in [ OpenAI ::Internal ::Util ::JSON_CONTENT , Hash | Array | -> { primitive? ( _1 ) } ]
573
- [ headers , JSON . fast_generate ( body ) ]
573
+ [ headers , JSON . generate ( body ) ]
574
574
in [ OpenAI ::Internal ::Util ::JSONL_CONTENT , Enumerable ] unless body . is_a? ( OpenAI ::Internal ::Type ::FileInput )
575
- [ headers , body . lazy . map { JSON . fast_generate ( _1 ) } ]
575
+ [ headers , body . lazy . map { JSON . generate ( _1 ) } ]
576
576
in [ %r{^multipart/form-data} , Hash | OpenAI ::Internal ::Type ::FileInput ]
577
577
boundary , strio = encode_multipart_streaming ( body )
578
578
headers = { **headers , "content-type" => "#{ content_type } ; boundary=#{ boundary } " }
Original file line number Diff line number Diff line change @@ -327,4 +327,4 @@ def test_default_headers
327
327
headers . each { refute_empty ( _1 ) }
328
328
end
329
329
end
330
- end
330
+ end
You can’t perform that action at this time.
0 commit comments