Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
sergiught committed Apr 15, 2023
1 parent 1078c79 commit 18973ca
Show file tree
Hide file tree
Showing 20 changed files with 442 additions and 444 deletions.
1 change: 1 addition & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ require (
github.com/yuin/goldmark v1.5.2 // indirect
github.com/yuin/goldmark-emoji v1.0.1 // indirect
golang.org/x/crypto v0.7.0 // indirect
golang.org/x/exp v0.0.0-20230321023759-10a507213a29 // indirect
golang.org/x/mod v0.8.0 // indirect
golang.org/x/net v0.9.0 // indirect
golang.org/x/tools v0.6.0 // indirect
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,8 @@ golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8U
golang.org/x/crypto v0.0.0-20220427172511-eb4f295cb31f/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
golang.org/x/crypto v0.7.0 h1:AvwMYaRytfdeVt3u6mLaxYtErKYjxA2OXjJ1HHq6t3A=
golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU=
golang.org/x/exp v0.0.0-20230321023759-10a507213a29 h1:ooxPy7fPvB4kwsA2h+iBNHkAbp/4JxTSwCmvdjEYmug=
golang.org/x/exp v0.0.0-20230321023759-10a507213a29/go.mod h1:CxIveKay+FTh1D0yPZemJVgC/95VzuuOLq5Qi4xnoYc=
golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.8.0 h1:LUYupSeNrTNCGzR/hVBk2NHZO4hXcVaW1k4Qx7rjPx8=
golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs=
Expand Down
2 changes: 1 addition & 1 deletion internal/cli/actions.go
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@ func openActionCmd(cli *cli) *cobra.Command {
inputs.ID = args[0]
}

openManageURL(cli, cli.config.DefaultTenant, formatActionDetailsPath(url.PathEscape(inputs.ID)))
openManageURL(cli, cli.Config.DefaultTenant, formatActionDetailsPath(url.PathEscape(inputs.ID)))
return nil
},
}
Expand Down
2 changes: 1 addition & 1 deletion internal/cli/apis.go
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ func openAPICmd(cli *cli) *cobra.Command {
}
}

openManageURL(cli, cli.config.DefaultTenant, formatAPISettingsPath(inputs.ID))
openManageURL(cli, cli.Config.DefaultTenant, formatAPISettingsPath(inputs.ID))
return nil
},
}
Expand Down
8 changes: 4 additions & 4 deletions internal/cli/apps.go
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ func useAppCmd(cli *cli) *cobra.Command {
}
}

if err := cli.setDefaultAppID(inputs.ID); err != nil {
if err := cli.Config.SaveNewDefaultAppIDForTenant(cli.tenant, inputs.ID); err != nil {
return err
}

Expand Down Expand Up @@ -479,7 +479,7 @@ func createAppCmd(cli *cli) *cobra.Command {
return fmt.Errorf("Unable to create application: %v", err)
}

if err := cli.setDefaultAppID(a.GetClientID()); err != nil {
if err := cli.Config.SaveNewDefaultAppIDForTenant(cli.tenant, a.GetClientID()); err != nil {
return err
}

Expand Down Expand Up @@ -737,7 +737,7 @@ func openAppCmd(cli *cli) *cobra.Command {
inputs.ID = args[0]
}

openManageURL(cli, cli.config.DefaultTenant, formatAppSettingsPath(inputs.ID))
openManageURL(cli, cli.Config.DefaultTenant, formatAppSettingsPath(inputs.ID))
return nil
},
}
Expand Down Expand Up @@ -879,7 +879,7 @@ func (c *cli) appPickerOptions(requestOpts ...management.RequestOption) pickerOp
return nil, err
}

tenant, err := c.getTenant()
tenant, err := c.Config.GetTenant(c.tenant)
if err != nil {
return nil, err
}
Expand Down
Loading

0 comments on commit 18973ca

Please sign in to comment.