Skip to content
This repository was archived by the owner on Feb 16, 2023. It is now read-only.

Commit 0c71e12

Browse files
committed
Remove 'CreatedBy' field from the output of account inspect for services
1 parent ea9aa7e commit 0c71e12

2 files changed

Lines changed: 0 additions & 5 deletions

File tree

internals/secrethub/account_inspect.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,15 +107,13 @@ func newOutputUser(user *api.User, timeFormatter TimeFormatter) *outputUser {
107107
// outputService is a user friendly JSON representation of a service account.
108108
type outputService struct {
109109
Description string
110-
CreatedBy string
111110
CreatedAt string `json:",omitempty"`
112111
outputAccount
113112
}
114113

115114
func newOutputService(service *api.Service, account *api.Account, timeFormatter TimeFormatter) *outputService {
116115
return &outputService{
117116
Description: service.Description,
118-
CreatedBy: service.CreatedBy.String(),
119117
CreatedAt: timeFormatter.Format(service.CreatedAt.Local()),
120118
outputAccount: outputAccount{
121119
AccountType: accountTypeService,

internals/secrethub/account_inspect_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ package secrethub
22

33
import (
44
"errors"
5-
"github.com/secrethub/secrethub-go/internals/api/uuid"
65
"testing"
76
"time"
87

@@ -87,7 +86,6 @@ func TestAccountInspect(t *testing.T) {
8786
return &api.Service{
8887
ServiceID: "s-abcdefghijkl",
8988
Description: "Test description.",
90-
CreatedBy: uuid.UUID{},
9189
CreatedAt: time.Date(2020, 12, 12, 12, 12, 12, 0, time.UTC),
9290
}, nil
9391
}
@@ -103,7 +101,6 @@ func TestAccountInspect(t *testing.T) {
103101
err: nil,
104102
out: `{
105103
"Description": "Test description.",
106-
"CreatedBy": "00000000-0000-0000-0000-000000000000",
107104
"CreatedAt": "2018-07-30T10:49:18Z",
108105
"AccountType": "service",
109106
"AccountName": "s-abcdefghijkl",

0 commit comments

Comments
 (0)