Skip to content

Commit

Permalink
Merge pull request #175 from openinfradev/fix_cloud_account
Browse files Browse the repository at this point in the history
bugfix. fix cloudaccount error when appgroup creating
  • Loading branch information
ktkfree authored Oct 26, 2023
2 parents 51034ed + 40a90f6 commit cfbf211
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions internal/usecase/app-group.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,11 @@ func (u *AppGroupUsecase) Create(ctx context.Context, dto domain.AppGroup) (id d
if err != nil {
return "", httpErrors.NewBadRequestError(fmt.Errorf("Failed to get cloudAccounts"), "", "")
}
tksCloudAccountId = cluster.CloudAccountId.String()
tksCloudAccountId = cluster.CloudAccount.ID.String()

isExist := false
for _, ca := range cloudAccounts {
if ca.ID == cluster.CloudAccountId {
if ca.ID == cluster.CloudAccount.ID {

// FOR TEST. ADD MAGIC KEYWORD
if strings.Contains(ca.Name, domain.CLOUD_ACCOUNT_INCLUSTER) {
Expand Down

0 comments on commit cfbf211

Please sign in to comment.