Additional defensiveness in ArbitraryDataFile.fromHash() to avoid similar future bugs.

This commit is contained in:
CalDescent 2022-03-05 17:25:48 +00:00
parent 18d5c924e6
commit 146d234dec

View File

@ -110,6 +110,9 @@ public class ArbitraryDataFile {
}
public static ArbitraryDataFile fromHash(byte[] hash, byte[] signature) throws DataException {
if (hash == null) {
return null;
}
return ArbitraryDataFile.fromHash58(Base58.encode(hash), signature);
}