mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-13 11:25:19 +00:00
Fix code implicitly casting clientsets to getters
This commit is contained in:
@@ -265,7 +265,7 @@ func updateTestContext() error {
|
||||
|
||||
// getNode gets node object from the apiserver.
|
||||
func getNode(c *clientset.Clientset) (*v1.Node, error) {
|
||||
nodes, err := c.Nodes().List(metav1.ListOptions{})
|
||||
nodes, err := c.CoreV1().Nodes().List(metav1.ListOptions{})
|
||||
Expect(err).NotTo(HaveOccurred(), "should be able to list nodes.")
|
||||
if nodes == nil {
|
||||
return nil, fmt.Errorf("the node list is nil.")
|
||||
|
||||
Reference in New Issue
Block a user