HomePhabricator

[ecash-lib] Use `new Error` when throwing errors in `WriterBytes`

Description

[ecash-lib] Use new Error when throwing errors in WriterBytes

Summary: Currently we throw strings directly, and node refuses to give us a stack trace in this case and tells us to use Error instead, so we do that.

Test Plan: npm run test

Reviewers: bytesofman, #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D16740

Details

Provenance
tobias_ruckAuthored on Sep 10 2024, 10:29
tobias_ruckPushed on Sep 10 2024, 22:26
Reviewer
Restricted Project
Differential Revision
D16740: [ecash-lib] Use `new Error` when throwing errors in `WriterBytes`
Parents
rABC2b4a9c3ae019: [e.cash] update meta description
Branches
Unknown
Tags
Unknown