Page MenuHomePhabricator

[Cashtab] Upgrade cashtab msg bytecount function
ClosedPublic

Authored by bytesofman on Jan 3 2024, 23:59.

Details

Reviewers
PiRK
Group Reviewers
Restricted Project
Commits
rABC4a2f09655bd3: [Cashtab] Upgrade cashtab msg bytecount function
Summary

Legacy function getMessageByteSize is overloaded and designed to handle now-deprecated encrypted msgs. It is also the last holdout still using the legacy generateOpReturnScript, which has been replaced by better functions in the src/opreturn directory.

Write a simpler function to get bytecount for Cashtab msgs. Add same unit tests as old function and some others.

Delete now unused functions getMessageByteSize and generateOpReturnScript.

Implement in Send.js

Test Plan

npm test
grep -r generateOpReturnScript src/ and no output

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

remove legacy function no longer used

bytesofman published this revision for review.Jan 4 2024, 00:03
bytesofman edited the test plan for this revision. (Show Details)
bytesofman edited the summary of this revision. (Show Details)
This revision is now accepted and ready to land.Jan 4 2024, 08:52