You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I use an async / await approach in the time-service client example - the promise always rejects. The error contains a proper response from the time-server though.
I believe that's because axon's send() method uses callback(result) convention, while requester.js expects callback(err, result) convention.
Also, the typings for cote declare send() method as one expecting callback(error, result). But it is not the case according to the docs anymore.
The text was updated successfully, but these errors were encountered:
If you're making use of promises (as in the case of async/await) and use callbacks in the responder, the first parameter should be the error. If you only use callbacks, there's no such convention. An easy way to fix this is to always use promises or always use callbacks.
The typings are not official, and done by the community. I'd love to have someone correct them.
If I use an async / await approach in the time-service client example - the promise always rejects. The error contains a proper response from the time-server though.
client.js example:
I believe that's because axon's
send()
method usescallback(result)
convention, while requester.js expectscallback(err, result)
convention.Also, the typings for cote declare
send()
method as one expectingcallback(error, result)
. But it is not the case according to the docs anymore.The text was updated successfully, but these errors were encountered: