mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-21 14:19:49 +08:00
Merge pull request #14275 from swordqiu/hotfix/qj-fail-to-update-usb-devs
fix: fail to update isolated_devices of type USB
This commit is contained in:
@@ -186,7 +186,7 @@ func (self *SIsolatedDevice) ValidateUpdateData(
|
||||
if input.ReservedStorage != nil && *input.ReservedStorage < 0 {
|
||||
return input, httperrors.NewInputParameterError("reserved storage must >= 0")
|
||||
}
|
||||
if input.DevType != "" {
|
||||
if input.DevType != "" && input.DevType != self.DevType {
|
||||
if !utils.IsInStringArray(input.DevType, api.VALID_GPU_TYPES) {
|
||||
return input, httperrors.NewInputParameterError("device type %q not support update", input.DevType)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user