mirror of
https://github.com/pocketbase/pocketbase.git
synced 2026-11-06 12:07:25 +01:00
allow invalid utf8 characters when marshalizing json responses
This commit is contained in:
1 parent
50f5f83ace
commit
756b326bfa
9 files changed
+57
-20
No files matched your search
@@ -62,11 +62,11 @@ func TestPickFields(t *testing.T) {
|
||||
"slice of maps with existing and missing fields",
|
||||
[]any{
|
||||
map[string]any{"a": 11, "b": 11, "c": "test1"},
|
||||
map[string]any{"a": 22, "b": 22, "c": "test2"},
|
||||
map[string]any{"a": 22, "b": 22, "c": "\xc3" /* test invalid utf8 mangling */},
|
||||
},
|
||||
"a, c ,missing", // test individual fields trim
|
||||
false,
|
||||
`[{"a":11,"c":"test1"},{"a":22,"c":"test2"}]`,
|
||||
`[{"a":11,"c":"test1"},{"a":22,"c":"�"}]`,
|
||||
},
|
||||
{
|
||||
"nested fields with mixed map and any slices",
|
||||
|
||||
Reference in new issue
Block a user