Skip to content

Commit

Permalink
Update base58.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
digicontributer authored Jan 14, 2018
1 parent 86d73c2 commit f9aed6d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/base58.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,8 @@ bool CBitcoinAddress::IsValid() const
bool CBitcoinAddress::IsValid(const CChainParams& params) const
{
bool fCorrectSize = vchData.size() == 20;
bool fKnownVersion = vchVersion == params.Base58Prefix(CChainParams::PUBKEY_ADDRESS);
bool fKnownVersion = vchVersion == params.Base58Prefix(CChainParams::PUBKEY_ADDRESS) ||
vchVersion == params.Base58Prefix(CChainParams::SCRIPT_ADDRESS);
return fCorrectSize && fKnownVersion;
}

Expand Down

0 comments on commit f9aed6d

Please sign in to comment.