mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-19 18:02:01 +00:00
Cleanup CopyFile
This commit is contained in:
parent
575031b68f
commit
3a54e3e56a
@ -36,7 +36,10 @@ func SetKubernetesVersion(cfg *kubeadmapiv1.ClusterConfiguration) {
|
||||
|
||||
// CopyFile copy file from src to dest.
|
||||
func CopyFile(src, dest string) error {
|
||||
fileInfo, _ := os.Stat(src)
|
||||
fileInfo, err := os.Stat(src)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
contents, err := os.ReadFile(src)
|
||||
if err != nil {
|
||||
return err
|
||||
|
Loading…
Reference in New Issue
Block a user