Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Do not panic when nil is passed in as a query parameter to a pointer of type that implements driver.Valuer via a value receiver #296

Merged
merged 3 commits into from
Sep 30, 2024

Conversation

drewthor
Copy link
Contributor

Pass nil to the database when a nil pointer to a type that implements driver.Valuer via a value receiver; this follows the behavior of database/sql

Fixes #295

…nter of type that implements driver.Valuer via a value receiver

Pass nil to the database when a nil pointer to a type that implements driver.Valuer via a value receiver; this follows the behavior of database/sql
@drewthor drewthor requested a review from a team as a code owner September 29, 2024 21:44
Copy link

google-cla bot commented Sep 29, 2024

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@olavloite olavloite merged commit 816847b into googleapis:main Sep 30, 2024
17 checks passed
gcf-merge-on-green bot pushed a commit that referenced this pull request Sep 30, 2024
🤖 I have created a release *beep* *boop*
---


## [1.7.2](https://togithub.com/googleapis/go-sql-spanner/compare/v1.7.1...v1.7.2) (2024-09-30)


### Bug Fixes

* Do not panic when nil is passed in as a query parameter to a pointer of type that implements driver.Valuer via a value receiver ([#296](https://togithub.com/googleapis/go-sql-spanner/issues/296)) ([816847b](https://togithub.com/googleapis/go-sql-spanner/commit/816847b09031a272af228350448d774d97ee6d7b))

---
This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Passing nil to pointers of types that implement driver.Valuer via value receivers panics
2 participants