mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-28 04:53:11 +00:00
Merge pull request #46688 from zhangxiaoyu-zidif/change-method-kubectl-configmap
Automatic merge from submit-queue Fix error message of isDir **What this PR does / why we need it**: Use IsRegular to replace isDir Accoding to the code logic, using IsRegular is proper. **Release note**: ```release-note NONE ```
This commit is contained in:
commit
4db120cc04
@ -218,7 +218,7 @@ func handleConfigMapFromEnvFileSource(configMap *api.ConfigMap, envFileSource st
|
||||
}
|
||||
}
|
||||
if info.IsDir() {
|
||||
return fmt.Errorf("must be a file")
|
||||
return fmt.Errorf("env config file cannot be a directory")
|
||||
}
|
||||
|
||||
return addFromEnvFile(envFileSource, func(key, value string) error {
|
||||
|
Loading…
Reference in New Issue
Block a user