From 3186d953119027ce6bb41fde714b1644bd0a671e Mon Sep 17 00:00:00 2001 From: Ying Huang Date: Thu, 25 Aug 2022 21:09:40 +0000 Subject: [PATCH] Issue 148 - code fix after merge. --- resource-management/pkg/service-api/endpoints/installer.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resource-management/pkg/service-api/endpoints/installer.go b/resource-management/pkg/service-api/endpoints/installer.go index b0de6532..19e34a59 100644 --- a/resource-management/pkg/service-api/endpoints/installer.go +++ b/resource-management/pkg/service-api/endpoints/installer.go @@ -134,8 +134,8 @@ func (i *Installer) NodeHandler(resp http.ResponseWriter, req *http.Request) { resp.Header().Set("Content-Type", "text/plain") region := location.GetRegionFromRegionName(regionName) - resourceParition := location.GetPartitionFromPartitionName(rpName) - if region == location.Region(-1) || resourceParition == location.ResourcePartition(-1) { + resourceParition, err := location.GetPartitionFromPartitionName(rpName) + if err != nil { resp.WriteHeader(http.StatusBadRequest) return }