avoid double formatting svacct policy (#3878)
This commit is contained in:
@@ -83,14 +83,14 @@ func checkAdminUserSvcAcctAddSyntax(ctx *cli.Context) {
|
||||
// svcAcctMessage container for content message structure
|
||||
type svcAcctMessage struct {
|
||||
op string
|
||||
Status string `json:"status"`
|
||||
AccessKey string `json:"accessKey,omitempty"`
|
||||
SecretKey string `json:"secretKey,omitempty"`
|
||||
ParentUser string `json:"parentUser,omitempty"`
|
||||
ImpliedPolicy bool `json:"impliedPolicy,omitempty"`
|
||||
Policy string `json:"policy,omitempty"`
|
||||
AccountStatus string `json:"accountStatus,omitempty"`
|
||||
MemberOf []string `json:"memberOf,omitempty"`
|
||||
Status string `json:"status"`
|
||||
AccessKey string `json:"accessKey,omitempty"`
|
||||
SecretKey string `json:"secretKey,omitempty"`
|
||||
ParentUser string `json:"parentUser,omitempty"`
|
||||
ImpliedPolicy bool `json:"impliedPolicy,omitempty"`
|
||||
Policy json.RawMessage `json:"policy,omitempty"`
|
||||
AccountStatus string `json:"accountStatus,omitempty"`
|
||||
MemberOf []string `json:"memberOf,omitempty"`
|
||||
}
|
||||
|
||||
const (
|
||||
|
||||
@@ -22,6 +22,7 @@ import (
|
||||
|
||||
"github.com/fatih/color"
|
||||
"github.com/minio/cli"
|
||||
json "github.com/minio/colorjson"
|
||||
"github.com/minio/mc/pkg/probe"
|
||||
"github.com/minio/pkg/console"
|
||||
)
|
||||
@@ -95,7 +96,7 @@ func mainAdminUserSvcAcctInfo(ctx *cli.Context) error {
|
||||
AccountStatus: svcInfo.AccountStatus,
|
||||
ParentUser: svcInfo.ParentUser,
|
||||
ImpliedPolicy: svcInfo.ImpliedPolicy,
|
||||
Policy: svcInfo.Policy,
|
||||
Policy: json.RawMessage(svcInfo.Policy),
|
||||
})
|
||||
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user