-
Notifications
You must be signed in to change notification settings - Fork 10.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make
MessageHandler.prototype.send
able to handle Error
s properly
Currently the "DocException" message requires manual handling of `Error`s on both the main- and worker-threads, which leads to some code duplication. Note that the `MessageHandler` implementation already deals with `Error`s when its `sendWithPromise` respectively `sendWithStream` methods are used, and it's easy enough to extend this to also apply to the `send` method. Finally, changes the `wrapReason` helper function to use a slightly shorter parameter name.
- Loading branch information
1 parent
4547f23
commit 8d773a9
Showing
3 changed files
with
21 additions
and
61 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters