Skip to content

Commit

Permalink
fix not encoding nil to null
Browse files Browse the repository at this point in the history
  • Loading branch information
tiltwind committed Nov 27, 2023
1 parent 3cf574c commit 6bb6218
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion java_lang_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -258,4 +258,4 @@ func doJavaLangObjectHolderTest(t *testing.T, holder *JavaLangObjectHolder) {
t.FailNow()
}
assert.Equal(t, des, holder)
}
}
8 changes: 4 additions & 4 deletions map.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,10 +96,10 @@ func getMapKey(key reflect.Value, t reflect.Type) (interface{}, error) {
// - `value` is the reflect value of the map
func (e *Encoder) encMap(m interface{}, value reflect.Value) error {
var (
err error
k interface{}
typ reflect.Type
keys []reflect.Value
err error
k interface{}
typ reflect.Type
keys []reflect.Value
)

// check ref
Expand Down

0 comments on commit 6bb6218

Please sign in to comment.