mirror of
				https://github.com/optim-enterprises-bv/kubernetes.git
				synced 2025-11-04 04:08:16 +00:00 
			
		
		
		
	fix staticcheck errors in pkg/controller/daemon.
Signed-off-by: Sakura <longfei.shang@daocloud.io>
This commit is contained in:
		@@ -1,6 +1,5 @@
 | 
				
			|||||||
cluster/images/etcd-version-monitor
 | 
					cluster/images/etcd-version-monitor
 | 
				
			||||||
cluster/images/etcd/migrate
 | 
					cluster/images/etcd/migrate
 | 
				
			||||||
pkg/controller/daemon
 | 
					 | 
				
			||||||
pkg/controller/deployment
 | 
					pkg/controller/deployment
 | 
				
			||||||
pkg/controller/disruption
 | 
					pkg/controller/disruption
 | 
				
			||||||
pkg/controller/garbagecollector
 | 
					pkg/controller/garbagecollector
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -305,16 +305,6 @@ func (dsc *DaemonSetsController) enqueue(ds *apps.DaemonSet) {
 | 
				
			|||||||
	dsc.queue.Add(key)
 | 
						dsc.queue.Add(key)
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func (dsc *DaemonSetsController) enqueueRateLimited(ds *apps.DaemonSet) {
 | 
					 | 
				
			||||||
	key, err := controller.KeyFunc(ds)
 | 
					 | 
				
			||||||
	if err != nil {
 | 
					 | 
				
			||||||
		utilruntime.HandleError(fmt.Errorf("Couldn't get key for object %#v: %v", ds, err))
 | 
					 | 
				
			||||||
		return
 | 
					 | 
				
			||||||
	}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
	dsc.queue.AddRateLimited(key)
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
func (dsc *DaemonSetsController) enqueueDaemonSetAfter(obj interface{}, after time.Duration) {
 | 
					func (dsc *DaemonSetsController) enqueueDaemonSetAfter(obj interface{}, after time.Duration) {
 | 
				
			||||||
	key, err := controller.KeyFunc(obj)
 | 
						key, err := controller.KeyFunc(obj)
 | 
				
			||||||
	if err != nil {
 | 
						if err != nil {
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -223,7 +223,6 @@ type fakePodControl struct {
 | 
				
			|||||||
	podStore     cache.Store
 | 
						podStore     cache.Store
 | 
				
			||||||
	podIDMap     map[string]*v1.Pod
 | 
						podIDMap     map[string]*v1.Pod
 | 
				
			||||||
	expectations controller.ControllerExpectationsInterface
 | 
						expectations controller.ControllerExpectationsInterface
 | 
				
			||||||
	dsc          *daemonSetsController
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func newFakePodControl() *fakePodControl {
 | 
					func newFakePodControl() *fakePodControl {
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user