Skip to content

Commit

Permalink
ignore if volume exists in MakeVolBulk, return other errors (minio#13866
Browse files Browse the repository at this point in the history
)
  • Loading branch information
harshavardhana authored Dec 9, 2021
1 parent 85d2df0 commit 3b79f7e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions cmd/xl-storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -679,10 +679,8 @@ func (s *xlStorage) SetDiskID(id string) {

func (s *xlStorage) MakeVolBulk(ctx context.Context, volumes ...string) error {
for _, volume := range volumes {
if err := s.MakeVol(ctx, volume); err != nil {
if errors.Is(err, errDiskAccessDenied) {
return errDiskAccessDenied
}
if err := s.MakeVol(ctx, volume); err != nil && !errors.Is(err, errVolumeExists) {
return err
}
}
return nil
Expand Down

0 comments on commit 3b79f7e

Please sign in to comment.