fix(az): config directory folder order

This commit is contained in:
Carl in 't Veld 2022-09-25 22:09:12 +02:00 committed by Jan De Dobbeleer
parent 99e226d167
commit a16f18f9ec

View file

@ -174,9 +174,9 @@ func (a *Az) getModuleSubscription() bool {
func (a *Az) findConfig(fileName string) (string, error) {
configDirs := []string{
a.env.Getenv("AZURE_CONFIG_DIR"),
filepath.Join(a.env.Home(), ".azure"),
filepath.Join(a.env.Home(), ".Azure"),
a.env.Getenv("AZURE_CONFIG_DIR"),
}
for _, dir := range configDirs {
if len(dir) != 0 && a.env.HasFilesInDir(dir, fileName) {