mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-10-31 02:38:07 +08:00
fix(region): make parseDeviceInfo error clear (#21326)
This commit is contained in:
@@ -484,7 +484,7 @@ func (manager *SIsolatedDeviceManager) parseDeviceInfo(userCred mcclient.TokenCr
|
||||
|
||||
if len(devId) == 0 {
|
||||
if matchDev == nil {
|
||||
return nil, fmt.Errorf("Isolated device info not contains either deviceID or model name")
|
||||
return nil, httperrors.NewNotFoundError("Not found matched device by model: %q, dev_type: %q", devConfig.Model, devConfig.DevType)
|
||||
}
|
||||
devConfig.Model = matchDev.Model
|
||||
if len(devVendor) > 0 {
|
||||
|
||||
Reference in New Issue
Block a user