validateChecksum static method
void
validateChecksum()
Validate address checksum.
Implementation
static void validateChecksum(
List<int> payloadBytes,
List<int> checksumBytesExp,
List<int> Function(List<int>) checksumFct,
) {
final checksumBytesGot = checksumFct(payloadBytes);
if (!BytesUtils.bytesEqual(checksumBytesExp, checksumBytesGot)) {
throw const AddressConverterException('Invalid checksum');
}
}