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

Flatten parameters in multipart requests #600

Merged
merged 1 commit into from
Apr 26, 2019
Merged

Conversation

ob-stripe
Copy link
Contributor

r? @rattrayalex-stripe
cc @stripe/api-libraries

Allows for nested parameters in multipart requests (i.e. file creation requests).

lib/utils.js Outdated Show resolved Hide resolved
Copy link
Contributor

@rattrayalex-stripe rattrayalex-stripe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure this will work as desired with arrays – can we add a test?

r? @ob-stripe

@ob-stripe
Copy link
Contributor Author

@rattrayalex-stripe TBC, you should only pass params objects to flattenAndStringify, it's not meant to work with arrays. But I can add a check and an explicit error if you think that's preferable.

@rattrayalex-stripe
Copy link
Contributor

Ah okay.

LGTM

@ob-stripe
Copy link
Contributor Author

Thanks Alex!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants