mirror of
https://github.com/kaspanet/kaspad.git
synced 2025-11-24 14:35:53 +00:00
fix verion checking logic
This commit is contained in:
parent
d7d3c72cf3
commit
73db64d991
@ -173,15 +173,15 @@ func CheckIfAddressIsValid(addr string, expectedPrefix Bech32Prefix) bool {
|
|||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
if version != pubKeyAddrID {
|
if version == pubKeyAddrID {
|
||||||
return false
|
return true
|
||||||
} else if version != pubKeyECDSAAddrID {
|
} else if version == pubKeyECDSAAddrID {
|
||||||
return false
|
return true
|
||||||
} else if version != scriptHashAddrID {
|
} else if version == scriptHashAddrID {
|
||||||
return false
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
return true
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
// PublicKeySize is the public key size for a schnorr public key
|
// PublicKeySize is the public key size for a schnorr public key
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user