@@ -4,14 +4,14 @@ import (
44 "context"
55 "encoding/json"
66 "fmt"
7- "github.com/stackitcloud/stackit-cli/internal/pkg/flags"
87 "strings"
98
109 "github.com/goccy/go-yaml"
1110
1211 "github.com/stackitcloud/stackit-cli/internal/pkg/args"
1312 "github.com/stackitcloud/stackit-cli/internal/pkg/errors"
1413 "github.com/stackitcloud/stackit-cli/internal/pkg/examples"
14+ "github.com/stackitcloud/stackit-cli/internal/pkg/flags"
1515 "github.com/stackitcloud/stackit-cli/internal/pkg/globalflags"
1616 "github.com/stackitcloud/stackit-cli/internal/pkg/print"
1717 "github.com/stackitcloud/stackit-cli/internal/pkg/services/iaas/client"
@@ -191,17 +191,13 @@ func outputResult(p *print.Printer, outputFormat string, server *iaas.Server) er
191191
192192 if server .ServiceAccountMails != nil && len (* server .ServiceAccountMails ) > 0 {
193193 emails := []string {}
194- for _ , email := range * server .ServiceAccountMails {
195- emails = append (emails , email )
196- }
194+ emails = append (emails , * server .ServiceAccountMails ... )
197195 table .AddRow ("SERVICE ACCOUNTS" , strings .Join (emails , "\n " ))
198196 }
199197
200198 if server .Volumes != nil && len (* server .Volumes ) > 0 {
201199 volumes := []string {}
202- for _ , volume := range * server .Volumes {
203- volumes = append (volumes , volume )
204- }
200+ volumes = append (volumes , * server .Volumes ... )
205201 table .AddRow ("VOLUMES" , strings .Join (volumes , "\n " ))
206202 }
207203
0 commit comments