Please sign in to comment.
worker: use correct ctor for error serialization
When serializing errors, use the error constructor that is closest to the object itself in the prototype chain. The previous practice of walking downwards meant that `Error` would usually be the first constructor that is used, even when a more specific one would be available/appropriate, because it is the base class of the other common error types. PR-URL: #25951 Reviewed-By: James M Snell <firstname.lastname@example.org> Reviewed-By: Gus Caplan <email@example.com> Reviewed-By: Benjamin Gruenbaum <firstname.lastname@example.org> Reviewed-By: Minwoo Jung <email@example.com> Reviewed-By: Colin Ihrig <firstname.lastname@example.org>
- Loading branch information...
Showing with 3 additions and 1 deletion.