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

Improve generic extension in search and getSearch #1425

Closed
bidoubiwa opened this issue Dec 13, 2022 · 0 comments · Fixed by #1446
Closed

Improve generic extension in search and getSearch #1425

bidoubiwa opened this issue Dec 13, 2022 · 0 comments · Fixed by #1446
Labels
good first issue Good for newcomers maintenance Issue about maintenance (CI, tests, refacto...)

Comments

@bidoubiwa
Copy link
Contributor

In the following methods:

async searchGet<D = T>(

and

async search<D = T>(

The generic D should always extend Record<string, any>.

Thus, they should be added in the generic definition like this

 async searchGet<D extends Record<string, any> = T>
@bidoubiwa bidoubiwa added good first issue Good for newcomers maintenance Issue about maintenance (CI, tests, refacto...) labels Dec 13, 2022
@meili-bors meili-bors bot closed this as completed in bcfd31e Feb 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers maintenance Issue about maintenance (CI, tests, refacto...)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant