@@ -26,15 +26,15 @@ func policy_getKeyAccessRegistry(cmd *cobra.Command, args []string) {
2626 }
2727
2828 keyType := "Local"
29- key := kas .PublicKey .GetLocal ()
29+ key := kas .GetPublicKey () .GetLocal ()
3030 if kas .PublicKey .GetRemote () != "" {
3131 keyType = "Remote"
32- key = kas .PublicKey .GetRemote ()
32+ key = kas .GetPublicKey () .GetRemote ()
3333 }
3434
3535 rows := [][]string {
36- {"Id" , kas .Id },
37- {"URI" , kas .Uri },
36+ {"Id" , kas .GetId () },
37+ {"URI" , kas .GetUri () },
3838 {"PublicKey Type" , keyType },
3939 {"PublicKey" , key },
4040 }
@@ -43,7 +43,7 @@ func policy_getKeyAccessRegistry(cmd *cobra.Command, args []string) {
4343 }
4444
4545 t := cli .NewTabular (rows ... )
46- HandleSuccess (cmd , kas .Id , t , kas )
46+ HandleSuccess (cmd , kas .GetId () , t , kas )
4747}
4848
4949func policy_listKeyAccessRegistries (cmd * cobra.Command , args []string ) {
@@ -64,15 +64,15 @@ func policy_listKeyAccessRegistries(cmd *cobra.Command, args []string) {
6464 rows := []table.Row {}
6565 for _ , kas := range list {
6666 keyType := "Local"
67- key := kas .PublicKey .GetLocal ()
68- if kas .PublicKey .GetRemote () != "" {
67+ key := kas .GetPublicKey () .GetLocal ()
68+ if kas .GetPublicKey () .GetRemote () != "" {
6969 keyType = "Remote"
70- key = kas .PublicKey .GetRemote ()
70+ key = kas .GetPublicKey () .GetRemote ()
7171 }
7272
7373 rows = append (rows , table .NewRow (table.RowData {
74- "id" : kas .Id ,
75- "uri" : kas .Uri ,
74+ "id" : kas .GetId () ,
75+ "uri" : kas .GetUri () ,
7676 "pk_loc" : keyType ,
7777 "pk" : key ,
7878 }))
@@ -92,15 +92,15 @@ func policy_createKeyAccessRegistry(cmd *cobra.Command, args []string) {
9292 metadataLabels := flagHelper .GetStringSlice ("label" , metadataLabels , cli.FlagHelperStringSliceOptions {Min : 0 })
9393
9494 if local == "" && remote == "" {
95- e := fmt .Errorf ("A public key is required. Please pass either a local or remote public key" )
95+ e := fmt .Errorf ("a public key is required. Please pass either a local or remote public key" )
9696 cli .ExitWithError ("Issue with create flags 'public-key-local' and 'public-key-remote': " , e )
9797 }
9898
9999 key := & policy.PublicKey {}
100100 keyType := "Local"
101101 if local != "" {
102102 if remote != "" {
103- e := fmt .Errorf ("Only one public key is allowed. Please pass either a local or remote public key but not both" )
103+ e := fmt .Errorf ("only one public key is allowed. Please pass either a local or remote public key but not both" )
104104 cli .ExitWithError ("Issue with create flags 'public-key-local' and 'public-key-remote': " , e )
105105 }
106106 key .PublicKey = & policy.PublicKey_Local {Local : local }
@@ -129,7 +129,7 @@ func policy_createKeyAccessRegistry(cmd *cobra.Command, args []string) {
129129 }
130130 t := cli .NewTabular (rows ... )
131131
132- HandleSuccess (cmd , created .Id , t , created )
132+ HandleSuccess (cmd , created .GetId () , t , created )
133133}
134134
135135func policy_updateKeyAccessRegistry (cmd * cobra.Command , args []string ) {
@@ -201,11 +201,11 @@ func policy_deleteKeyAccessRegistry(cmd *cobra.Command, args []string) {
201201 }
202202
203203 t := cli .NewTabular (
204- []string {"Id" , "URI" },
205- []string {kas . Id , kas .Uri },
204+ []string {"Id" , kas . GetId () },
205+ []string {"URI" , kas .GetUri () },
206206 )
207207
208- HandleSuccess (cmd , kas .Id , t , kas )
208+ HandleSuccess (cmd , kas .GetId () , t , kas )
209209}
210210
211211func init () {
0 commit comments