mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-30 15:05:27 +00:00
Merge pull request #17058 from deads2k/fix-client-cache
Auto commit by PR queue bot
This commit is contained in:
commit
7c660bc240
@ -68,6 +68,11 @@ func (c *ClientCache) ClientConfigForVersion(version string) (*client.Config, er
|
||||
client.SetKubernetesDefaults(&config)
|
||||
c.configs[version] = &config
|
||||
|
||||
// `version` does not necessarily equal `config.Version`. However, we know that we call this method again with
|
||||
// `config.Version`, we should get the the config we've just built.
|
||||
configCopy := config
|
||||
c.configs[config.Version] = &configCopy
|
||||
|
||||
return &config, nil
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user