Skip to content

Commit 8f36015

Browse files
authored
Merge pull request #964 from ialidzhikov/nit/remove-duplication
Use existing error message format
2 parents 26813bb + fd50136 commit 8f36015

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/gce-pd-csi-driver/node.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ func (ns *GCENodeServer) NodeUnstageVolume(ctx context.Context, req *csi.NodeUns
356356
}
357357

358358
if acquired := ns.volumeLocks.TryAcquire(volumeID); !acquired {
359-
return nil, status.Error(codes.Aborted, fmt.Sprintf("An operation with the given Volume ID %s already exists", volumeID))
359+
return nil, status.Errorf(codes.Aborted, common.VolumeOperationAlreadyExistsFmt, volumeID)
360360
}
361361
defer ns.volumeLocks.Release(volumeID)
362362

0 commit comments

Comments
 (0)