-
Notifications
You must be signed in to change notification settings - Fork 558
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Symbolize hash keys inside convert_to_stripe_object_with_params
#1152
Symbolize hash keys inside convert_to_stripe_object_with_params
#1152
Conversation
Without this, perfectly good hash representations of Stripe classes get turned into generic `Stripe::StripeObject`s if they happen to have string keys.
Hi @mebezac, can you describe the scenario where you encounter this issue? |
When we get a webhook from Stripe, we usually pass the data along to a sidekiq worker. We'll quite often pass Inside jobs, we sometimes we want to use the familiar/convenient methods that a Stripe object gives us. That means we'll take the data (which has been JSON-serialized) and turn it back into a Stripe object using Thanks! |
Does using I'm a bit reluctant to put an extra |
@pakrym-stripe thanks for the feedback, how about the most recent commit? All that really matters is the |
The change looks good but the linter is unhappy. |
Thank you for contribution @mebezac ! |
Without this, perfectly good hash representations of Stripe classes get turned into generic
Stripe::StripeObject
s if they happen to have string keys.