paulmillr / scure-base

Secure, audited & 0-deps implementation of bech32, base64, base32, base16 & base58
https://paulmillr.com/noble/#scure
MIT License
106 stars 13 forks source link

fix: rename _words to prefix, do not assign lowered to str #27

Closed mahnunchik closed 8 months ago

mahnunchik commented 8 months ago

When I ported it to CashAddr, I noticed some points that could be made clearer:

  1. Do not use _words variable name because the same name is used in the upper scope. data name matches with the error message.
  2. Do not assign lowered to function parameter str for readability and original str in error message.
paulmillr commented 8 months ago

@mahnunchik all good with regards to the port itself?

mahnunchik commented 8 months ago

@paulmillr I'm working on it.

It was right idea to have separate module because I've to reuse btc-signer for legacy normal addresses.

paulmillr commented 8 months ago

If something doesn't work, please prepare a pr with all needed changes to make it work, so we can put it into one version: I don't want to release many scure-base releases in a row.