Commit eeda0ed
committed
Fix UTF-8 encoding issue with binary attachment content in JSON serialization
- Add normalize_json_encodings! method to handle binary attachment content
- Automatically base64 encode binary strings before JSON serialization
- Fixes 'source sequence is illegal/malformed utf-8' error when sending
attachments with raw binary content via JSON (non-multipart) requests
- Preserves backward compatibility with both symbol and string keys
- Resolves issue #5281 parent fc3b309 commit eeda0ed
1 file changed
+26
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
103 | 103 | | |
104 | 104 | | |
105 | 105 | | |
| 106 | + | |
106 | 107 | | |
107 | 108 | | |
108 | 109 | | |
| |||
257 | 258 | | |
258 | 259 | | |
259 | 260 | | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
260 | 286 | | |
261 | 287 | | |
262 | 288 | | |
| |||
0 commit comments