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

Bug: TRequestIdFunction is too stricly typed #137

Closed
jraoult opened this issue May 3, 2022 · 2 comments
Closed

Bug: TRequestIdFunction is too stricly typed #137

jraoult opened this issue May 3, 2022 · 2 comments
Labels
bug Something isn't working

Comments

@jraoult
Copy link

jraoult commented May 3, 2022

Describe the bug
While implementing a request id provider function, I realised that it is supported to return undefined from a TRequestIdFunction despite what the typing is enforcing. The requestId will not be shown in the log trace, which is very handy.

I think the type should be updated to reflect the runtime behaviour:

export type TRequestIdFunction = () => string | undefined;
@jraoult jraoult added the bug Something isn't working label May 3, 2022
@terehov
Copy link
Contributor

terehov commented Aug 23, 2022

That's correct, thank you. I'll fix it in the next release :-)

@terehov
Copy link
Contributor

terehov commented Aug 23, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants