From 2d51e423053aa5c655b11fece29dc4225ddb7314 Mon Sep 17 00:00:00 2001 From: mstmdev Date: Fri, 24 Mar 2023 05:06:22 +0800 Subject: [PATCH] Remove the redundant conditional in the validateParity function (#16866) --- internal/config/storageclass/storage-class.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/config/storageclass/storage-class.go b/internal/config/storageclass/storage-class.go index ba6d69e43..bd43c5bae 100644 --- a/internal/config/storageclass/storage-class.go +++ b/internal/config/storageclass/storage-class.go @@ -204,7 +204,7 @@ func validateParity(ssParity, rrsParity, setDriveCount int) (err error) { } if ssParity > 0 && rrsParity > 0 { - if ssParity > 0 && ssParity < rrsParity { + if ssParity < rrsParity { return fmt.Errorf("Standard storage class parity drives %d should be greater than or equal to Reduced redundancy storage class parity drives %d", ssParity, rrsParity) } }