mirror of
https://github.com/minio/minio.git
synced 2025-11-09 05:34:56 -05:00
Add number of offline disks in quorum errors (#16822)
This commit is contained in:
@@ -226,12 +226,10 @@ func toAdminAPIErr(ctx context.Context, err error) APIError {
|
||||
// toAdminAPIErrCode - converts errErasureWriteQuorum error to admin API
|
||||
// specific error.
|
||||
func toAdminAPIErrCode(ctx context.Context, err error) APIErrorCode {
|
||||
switch err {
|
||||
case errErasureWriteQuorum:
|
||||
if errors.Is(err, errErasureWriteQuorum) {
|
||||
return ErrAdminConfigNoQuorum
|
||||
default:
|
||||
return toAPIErrorCode(ctx, err)
|
||||
}
|
||||
return toAPIErrorCode(ctx, err)
|
||||
}
|
||||
|
||||
// wraps export error for more context
|
||||
|
||||
Reference in New Issue
Block a user