Skip to content

Commit

Permalink
Polish code
Browse files Browse the repository at this point in the history
Signed-off-by: Liu Ming <hit_oak_tree@126.com>
  • Loading branch information
liuming-dev committed Jul 29, 2020
1 parent 9ec5515 commit eaa3db4
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions pkg/kube/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ func GetKubernetesClient() (*kubernetes.Clientset, error) {

func getConfig() (*rest.Config, error) {
var config *rest.Config
var err error
kubeconfigPath := os.Getenv("KUBECONFIG")
if kubeconfigPath == "" {
kubeconfigPath = os.Getenv("HOME") + "/.kube/config"
Expand All @@ -95,9 +94,6 @@ func getConfig() (*rest.Config, error) {
return nil, err
}
}
if err != nil {
return nil, err
}

return config, nil
}

0 comments on commit eaa3db4

Please sign in to comment.