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

Inaсcurate TypeScript type for RepoConnection.get with Arrays #10044

Closed
tajakobsen opened this issue Feb 23, 2023 · 0 comments
Closed

Inaсcurate TypeScript type for RepoConnection.get with Arrays #10044

tajakobsen opened this issue Feb 23, 2023 · 0 comments
Assignees
Labels
Milestone

Comments

@tajakobsen
Copy link
Collaborator

If you pass in an Array of keys and the Array is of length=1 to nodeLibs RepoConnection.get(), the output will not be in an Array but a single value.

So the second and third overload is not typed for this possibility.

tajakobsen added a commit to tajakobsen/xp that referenced this issue Feb 23, 2023
Adds the possibility to get a single node returned if you pass in an
Array.

Also removes 3rd overload, because it has the same parameters
as the 4th, but is missing the case for the single node return.
alansemenov pushed a commit that referenced this issue Feb 24, 2023
Adds the possibility to get a single node returned if you pass in an
Array.

Also removes 3rd overload, because it has the same parameters
as the 4th, but is missing the case for the single node return.
alansemenov pushed a commit that referenced this issue Feb 24, 2023
Adds the possibility to get a single node returned if you pass in an
Array.

Also removes 3rd overload, because it has the same parameters
as the 4th, but is missing the case for the single node return.

(cherry picked from commit 9673444)
@rymsha rymsha added this to the 7.12.0 milestone Feb 24, 2023
@alansemenov alansemenov changed the title Inacurate TypeScript type for RepoConnection.get with Arrays Inaсcurate TypeScript type for RepoConnection.get with Arrays Feb 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants