What is Nostr?
Drew DeVault /
npub1qka…hctl
2023-09-28 09:15:12
in reply to nevent1q…g7wh

Drew DeVault on Nostr: npub1ku30m…dqwn9 the reason you cannot pass errors up through async function ...

npub1ku30mphs68tg30c4jj0d80g698resvue70hhrvnawxvdfaq4p0usadqwn9 (npub1ku3…qwn9) the reason you cannot pass errors up through async function handlers is that each callback is a terminal error site -- if you passed it back up, you'd have to exit the event loop entirely to handle it. So you gotta handle it there. But you can just stick the error in a value and pass it to some shared error handling code that does the meaningful for your use-case
Author Public Key
npub1qka6mt4yr5cv8nem07csya3zavqvefnxxh7fq3c98hmlnf2vkrrsykhctl