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 Table.bulkGet return typing to include undefined #1098

Merged
merged 1 commit into from
Aug 7, 2020

Conversation

medmunds
Copy link
Contributor

@medmunds medmunds commented Aug 6, 2020

This improves the typing for Table.bulkGet() to indicate
the returned array may include undefined items.

(Per the bulkGet docs, "For those keys that do not
exist in the database, undefined will be returned in their
place.")

This improves the typing for Table.bulkGet() to indicate
the returned array may include undefined items.

(Per the [bulkGet docs][], "For those keys that do not
exist in the database, undefined will be returned in their
place.")

[bulkGet docs]: https://dexie.org/docs/Table/Table.bulkGet()
@medmunds
Copy link
Contributor Author

medmunds commented Aug 6, 2020

(Not really sure how to test this, short of pulling in dtslint or tsd. But I did add a bulkGet to test-typings.ts, with a commented out line that should cause an error since it doesn't handle undefined.)

@medmunds
Copy link
Contributor Author

medmunds commented Aug 7, 2020

(Build passed; not sure why GH checks aren't updating: https://travis-ci.org/github/dfahlander/Dexie.js/builds/715647161)

@dfahlander dfahlander merged commit aebcb5e into dexie:master Aug 7, 2020
@dfahlander
Copy link
Collaborator

Thanks a lot!

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