Fixed loading bug when a transaction's data size is smaller than the chunk size.

This commit is contained in:
CalDescent 2021-11-03 21:54:57 +00:00
parent e50fd786da
commit b861b2dffb

View File

@ -282,7 +282,7 @@ public class ArbitraryDataReader {
// Load data file(s)
ArbitraryDataFile arbitraryDataFile = ArbitraryDataFile.fromHash(digest);
if (!arbitraryDataFile.exists()) {
if (!arbitraryDataFile.allChunksExist(chunkHashes)) {
if (!arbitraryDataFile.allChunksExist(chunkHashes) || chunkHashes == null) {
// Ask the arbitrary data manager to fetch data for this transaction
ArbitraryDataManager.getInstance().fetchDataForSignature(transactionData.getSignature());