mappum / bitcoin-net

:globe_with_meridians: Bitcoin networking that works in Node and the browser
24 stars 22 forks source link

Check if header is already a Block instance in transform #166

Open stephank opened 6 years ago

stephank commented 6 years ago

When overriding the header type in bitcoin-protocol, it's possible messages already contain Block instances (or a subclass thereof).

For webcoin-dogecoin, I'm actually implementing the abstract-encoding interface in a Block subclass, so that I can parse the optional auxpow data found in headers.