cleanup: return error type in detachRBDImageOrDeviceSpec()

Signed-off-by: Niels de Vos <ndevos@redhat.com>
This commit is contained in:
Niels de Vos 2020-12-08 15:06:48 +01:00 committed by mergify[bot]
parent 7eae69f10c
commit 729e2419ef

View File

@ -330,7 +330,7 @@ func detachRBDImageOrDeviceSpec(ctx context.Context, imageOrDeviceSpec string, i
util.TraceLog(ctx, "image or device spec (%s) not mapped", imageOrDeviceSpec) util.TraceLog(ctx, "image or device spec (%s) not mapped", imageOrDeviceSpec)
return nil return nil
} }
return fmt.Errorf("rbd: unmap for spec (%s) failed (%v): (%s)", imageOrDeviceSpec, err, stderr) return fmt.Errorf("rbd: unmap for spec (%s) failed (%w): (%s)", imageOrDeviceSpec, err, stderr)
} }
return nil return nil