Skip to content

Commit a6ccf29

Browse files
committed
update comments for StoredChunkDataPack.Equals
1 parent 36a9e08 commit a6ccf29

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

storage/chunk_data_packs_stored.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,9 @@ func ToStoredChunkDataPacks(cs []*flow.ChunkDataPack) []*StoredChunkDataPack { /
8686
}
8787

8888
// Equals compares two StoredChunkDataPack for equality.
89-
// The second return value is a string describing the first found mismatch, or empty if they are equal.
90-
func (c StoredChunkDataPack) Equals(other StoredChunkDataPack) (bool, string) {
89+
// It returns (true, "") if they are equal, otherwise (false, reason) where reason is the first
90+
// found reason for the mismatch.
91+
func (c StoredChunkDataPack) Equals(other StoredChunkDataPack) (equal bool, diffReason string) {
9192
if c.ChunkID != other.ChunkID {
9293
return false, fmt.Errorf("chunk ID mismatch: %s != %s", c.ChunkID, other.ChunkID).Error()
9394
}

0 commit comments

Comments
 (0)