Skip to content

feat: use generic on userinfo#263

Open
Joabesv wants to merge 3 commits intofastify:mainfrom
Joabesv:feat/generic-on-user-info
Open

feat: use generic on userinfo#263
Joabesv wants to merge 3 commits intofastify:mainfrom
Joabesv:feat/generic-on-user-info

Conversation

@Joabesv
Copy link
Copy Markdown

@Joabesv Joabesv commented Jun 28, 2024

hi there, just adding to avoid an as Type, and generic is compatible with Object so it shouldn't break anything (as it already didn't)

Checklist

Comment thread types/index.d.ts Outdated
@Eomm Eomm requested a review from Uzlopak September 22, 2024 09:26
@Joabesv
Copy link
Copy Markdown
Author

Joabesv commented Nov 1, 2024

hi guys, any comments here?

@Uzlopak
Copy link
Copy Markdown
Contributor

Uzlopak commented Nov 18, 2024

@Joabesv

Yeah, I checked it locally and it strange, that the Generic without default type is by default Object. Is this something new in typescript? I expected that we would get some type error, because we dont set the type in the tsd tests?

Please add a tsd test like this in index.test-d.ts at about line 286

expectType<{bla: string}>(await server.testOAuthName.userinfo<{bla: string}>(token.token.access_token));

Copy link
Copy Markdown
Contributor

@Uzlopak Uzlopak left a comment

Choose a reason for hiding this comment

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

LGTM

@Eomm
PTAL

Copy link
Copy Markdown
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

@Joabesv
Copy link
Copy Markdown
Author

Joabesv commented Nov 22, 2024

Thanks for the follow up on this!

@mcollina
Copy link
Copy Markdown
Member

@Joabesv I'm so sorry, but these conflicts now. Can you rebase/fix them?

@ilteoood
Copy link
Copy Markdown
Contributor

@Joabesv are you planning to solve the conflicts?

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.

5 participants