Skip to content

Commit

Permalink
fix: Relax constraint on unmarshaling param values
Browse files Browse the repository at this point in the history
  • Loading branch information
rlch committed Sep 15, 2023
1 parent 71ecb3d commit 7fb96ad
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion client_impl.go
Original file line number Diff line number Diff line change
Expand Up @@ -541,7 +541,7 @@ func canonicalizeParams(params map[string]any) (map[string]any, error) {
if err != nil {
return nil, fmt.Errorf("cannot marshal map: %w", err)
}
var js map[string]any
var js any
if err := json.Unmarshal(bytes, &js); err != nil {
return nil, fmt.Errorf("cannot unmarshal map: %w", err)
}
Expand Down
2 changes: 1 addition & 1 deletion driver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ func ExampleDriver() {
fmt.Printf("err: %v\n", err)
fmt.Printf("person: %v\n", person)
// Output:
// CREATE (person:Person {name: $person_name, surname: $person_surname})
// CREATE (person:Person {id: $person_id, name: $person_name, surname: $person_surname})
// SET person.age = $v1
// RETURN person
// err: <nil>
Expand Down

0 comments on commit 7fb96ad

Please sign in to comment.