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 nextPage typing in requests #3298

Merged
merged 1 commit into from Sep 8, 2023
Merged

Fix nextPage typing in requests #3298

merged 1 commit into from Sep 8, 2023

Conversation

ghost
Copy link

@ghost ghost commented Jun 9, 2020

The fixes the return type of the nextPage() method. Before, it would
return Request<D, E>|void which is hard to work with, because you
couldn't runtime test for void (everything can be void). This change
splits up the definition into two overloads: one without a callback
provided that returns Request<D, E> | null and a second for the
callback version that always returns void. This also matches the
documentation in the implementation now.

Checklist
  • npm run test passes
  • .d.ts file is updated
  • changelog is added, npm run add-change

The fixes the return type of the `nextPage()` method. Before, it would
return `Request<D, E>|void` which is hard to work with, because you
couldn't runtime test for `void` (everything can be void). This change
splits up the definition into two overloads: one without a callback
provided that returns `Request<D, E> | null` and a second for the
callback version that always returns `void`. This also matches the
documentation in the implementation now.
@aws-sdk-js-automation
Copy link

AWS CodeBuild CI Report

  • CodeBuild project: sdk-v2-github
  • Commit ID: 14de999
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@ajredniwja ajredniwja added the pr/needs-review This PR needs a review from a Member. label Jun 16, 2020
@siddsriv siddsriv merged commit 7a04f0c into aws:master Sep 8, 2023
@kiran-esper
Copy link

Much needed!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr/needs-review This PR needs a review from a Member.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants