Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The only place that `priv` is used in `signAsync` and `sign` is when it is passed to `prepSig`. The only place `priv` is used in `prepSig` is when it is passed to `toPriv`. `toPriv` takes a `PrivKey`, so that means `prepSig`, `sign`, and `signAsync` can also take a `PrivKey`. Functionally, this means that `bigint` is now allowed as a private key. This will make it so users who are storing private keys in memory as bigints will not have to first convert to hex. Node: Currently if you naively convert your bigint private key to hex using `0x${privateKey.toString(16)}` this library will throw an error complaining about the hex for the private key being the wrong length. Arguably this library should accept an odd length hex value for the private key, but in my case just accepting bigints directly would fix the issue and allowing odd length hex strings would require an actual code change rather than just a type change.
- Loading branch information