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

update PaymentSource.MarshalJSON to serialize bank accounts too #519

Merged

Conversation

tylerkovacs
Copy link
Contributor

This pull request fixes serialization for PaymentSourceBankAccount. PaymentSource has a MarshalJSON implementation with custom behavior based on type but there was no implementation for type PaymentSourceBankAccount so bank accounts were being serialized as null.

@brandur-stripe
Copy link
Contributor

Makes sense. Thanks for adding that bonus test too!

Just out of curiosity, what exactly are you using this for?

I was a little surprised to find that it even existed, and had to dig back for context to #88 to see why.

@brandur-stripe brandur-stripe merged commit f9ff4ac into stripe:master Feb 16, 2018
@brandur-stripe
Copy link
Contributor

Released as 29.0.1.

@tylerkovacs
Copy link
Contributor Author

Thanks for the merge.

My situation seems similar to #88. I'm building a Gmail Add-on for Stripe. In my case, the client is Gmail and requests are proxied through my servers rather than hitting Stripe directly. I noticed that the response from the Stripe API was correct, but became corrupt as soon as the objects were re-serialized on the way back to the client.

nadaismail-stripe pushed a commit that referenced this pull request Oct 18, 2024
Bumps [sorbet-runtime](https://github.com/sorbet/sorbet) from 0.5.10101 to 0.5.10109.
- [Release notes](https://github.com/sorbet/sorbet/releases)
- [Commits](https://github.com/sorbet/sorbet/commits)

---
updated-dependencies:
- dependency-name: sorbet-runtime
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
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.

2 participants