mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-06 10:43:56 +00:00
Remove useless variable and if
Signed-off-by: Ling Samuel <lingsamuelgrace@gmail.com>
This commit is contained in:
parent
a69a4a4bf0
commit
c7f2b2aa2f
@ -270,13 +270,9 @@ func makePodSourceConfig(kubeCfg *kubeletconfiginternal.KubeletConfiguration, ku
|
|||||||
config.NewSourceURL(kubeCfg.StaticPodURL, manifestURLHeader, nodeName, kubeCfg.HTTPCheckFrequency.Duration, cfg.Channel(kubetypes.HTTPSource))
|
config.NewSourceURL(kubeCfg.StaticPodURL, manifestURLHeader, nodeName, kubeCfg.HTTPCheckFrequency.Duration, cfg.Channel(kubetypes.HTTPSource))
|
||||||
}
|
}
|
||||||
|
|
||||||
var updatechannel chan<- interface{}
|
|
||||||
if kubeDeps.KubeClient != nil {
|
if kubeDeps.KubeClient != nil {
|
||||||
klog.Infof("Watching apiserver")
|
klog.Infof("Watching apiserver")
|
||||||
if updatechannel == nil {
|
config.NewSourceApiserver(kubeDeps.KubeClient, nodeName, cfg.Channel(kubetypes.ApiserverSource))
|
||||||
updatechannel = cfg.Channel(kubetypes.ApiserverSource)
|
|
||||||
}
|
|
||||||
config.NewSourceApiserver(kubeDeps.KubeClient, nodeName, updatechannel)
|
|
||||||
}
|
}
|
||||||
return cfg, nil
|
return cfg, nil
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user