Skip to content

Commit

Permalink
change order
Browse files Browse the repository at this point in the history
change order
  • Loading branch information
jiuker committed Aug 17, 2024
1 parent 5b01d0c commit 15eb9a2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion cmd/client-admin.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,13 @@ func NewAdminFactory() func(config *Config) (*madmin.AdminClient, *probe.Error)
var found bool
if api, found = clientCache[confSum]; !found {

transport := config.getTransport()

credsChain, err := config.getCredsChain()
if err != nil {
return nil, err
}

transport := config.getTransport()
creds := credentials.NewChainCredentials(credsChain)

// Not found. Instantiate a new MinIO
Expand Down
3 changes: 2 additions & 1 deletion cmd/client-s3.go
Original file line number Diff line number Diff line change
Expand Up @@ -240,12 +240,13 @@ func newFactory() func(config *Config) (Client, *probe.Error) {
var found bool
if api, found = clientCache[confSum]; !found {

transport := config.getTransport()

credsChain, err := config.getCredsChain()
if err != nil {
return nil, err
}

transport := config.getTransport()
if err != nil {
return nil, err
}
Expand Down

0 comments on commit 15eb9a2

Please sign in to comment.