We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
fn
Server.register
The type bound for fn in register has a void return type:
register
void
rpc-websockets/src/lib/server.ts
Line 147 in 46b0190
I'm rather new to TypeScript, but I would suggest a return type of unknown | Promise<unknown> to hint that the function is await'd later on:
unknown | Promise<unknown>
await
Lines 697 to 698 in 46b0190
The text was updated successfully, but these errors were encountered:
Hi, @SamWilsn, are there any issues you came across in production that's touching on this code?
Sorry, something went wrong.
are there any issues you came across in production that's touching on this code?
Here's an example:
https://github.com/wallet-test-framework/glue-ws/blob/0322225d8979f2d3995efb1d703d98c6f672f75d/src/index.ts#L68-L70
I have to disable the @typescript-eslint/no-misused-promises lint because the function doesn't declare that it may return a Promise.
@typescript-eslint/no-misused-promises
Promise
No branches or pull requests
The type bound for
fn
inregister
has avoid
return type:rpc-websockets/src/lib/server.ts
Line 147 in 46b0190
I'm rather new to TypeScript, but I would suggest a return type of
unknown | Promise<unknown>
to hint that the function isawait
'd later on:rpc-websockets/src/lib/server.ts
Lines 697 to 698 in 46b0190
The text was updated successfully, but these errors were encountered: