Fix "Number of valid pieces is lower then success threshold" (#1679)

This commit is contained in:
Kaloyan Raev 2019-04-05 13:19:20 +03:00 committed by GitHub
parent 5ea797889b
commit 92c1121072
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -413,10 +413,10 @@ func (endpoint *Endpoint) filterValidPieces(pointer *pb.Pointer) error {
remotePieces = append(remotePieces, piece) remotePieces = append(remotePieces, piece)
} }
if int32(len(remotePieces)) < remote.Redundancy.SuccessThreshold { if int32(len(remotePieces)) < remote.Redundancy.RepairThreshold {
return Error.New("Number of valid pieces is lower then success threshold: %v < %v", return Error.New("Number of valid pieces is lower then repair threshold: %v < %v",
len(remotePieces), len(remotePieces),
remote.Redundancy.SuccessThreshold, remote.Redundancy.RepairThreshold,
) )
} }