mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-24 16:03:43 +08:00
Automatic merge from release/2.4.0 -> release/2.5.0
* commit 'bac6404b4aec30c206ac68c1f8defc2b220ebc24': fix: zone create nil pointer access error
This commit is contained in:
@@ -601,7 +601,7 @@ func (self *SZone) getMaxDataDiskCount() int {
|
||||
}
|
||||
|
||||
func (manager *SZoneManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ownerProjId string, query jsonutils.JSONObject, data *jsonutils.JSONDict) (*jsonutils.JSONDict, error) {
|
||||
regionStr := jsonutils.GetAnyString(query, []string{"region", "region_id", "cloudregion", "cloudregion_id"})
|
||||
regionStr := jsonutils.GetAnyString(data, []string{"region", "region_id", "cloudregion", "cloudregion_id"})
|
||||
var regionId string
|
||||
if len(regionStr) > 0 {
|
||||
regionObj, err := CloudregionManager.FetchByIdOrName(nil, regionStr)
|
||||
|
||||
Reference in New Issue
Block a user