aryzing
aryzing9mo ago

Feature or happy accident: error message from `cause` being used as TRPC's error message

When a procedure throws a TRPC error with no message, it turns out that if the thrown error has a cause, and the cause has a message, the cause's message will be used as the TRPC error message returned to the client. Is this on purpose or an accident? Couldn't find this behavior documented.
0 Replies
No replies yetBe the first to reply to this messageJoin