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

Narrower type for stripe.invoices.retrieveUpcoming() #1629

merged 5 commits into from Dec 1, 2022


Copy link

@richardm-stripe richardm-stripe commented Nov 30, 2022

Fixes #1500,
Fixes #1013

Makes stripe.invoices.retrieveUpcoming return Omit<Invoice, 'id'> instead of Invoice. This means that can now be required and should prevent some needless null checks.

Copy link

@pakrym-stripe pakrym-stripe left a comment

Choose a reason for hiding this comment

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

Some questions.

types/UpcomingInvoices.d.ts Outdated Show resolved Hide resolved
types/test/typescriptTest.ts Show resolved Hide resolved
@richardm-stripe richardm-stripe merged commit 247c35e into master Dec 1, 2022
7 checks passed
@richardm-stripe richardm-stripe deleted the richardm-upcoming-invoice-narrower-type branch December 7, 2022 10:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

Successfully merging this pull request may close these issues. is shouldn't be optional invoices.retrieveUpcoming return type incorrect
2 participants