HomePhabricator

[herald] Fix parsing of the staking reward winner

Description

[herald] Fix parsing of the staking reward winner

Summary:
The parsing function returns the staker address. It's very possible that there is no address for the winner, so avoid crashing the app if this happens.
This diff lets the parsing return the script hex instead, and the callsite attempt to convert it to address so it will make no difference with the current network state.

Test Plan:

npm test

Reviewers: #bitcoin_abc, PiRK

Reviewed By: #bitcoin_abc, PiRK

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

Details

Provenance
FabienAuthored on Oct 7 2024, 08:39
FabienPushed on Oct 7 2024, 15:08
Parents
rSTAGINGe36e63a307a6: [herald] Fix the headers, lint the package
Branches
Unknown
Tags
Unknown
References
tag: phabricator/base/49971, tag: phabricator/base/49968, tag: phabricator/base/49967, tag: phabricator/base/49966

Event Timeline