This commit is contained in:
Kévin Dunglas
2024-11-19 00:05:06 +01:00
parent 1c4146c3ce
commit 4bddf3be1b

View File

@ -317,13 +317,15 @@ func parsePHPFastCGI(h httpcaddyfile.Helper) ([]httpcaddyfile.ConfigValue, error
tryFiles = []string{"{http.request.uri.path}", "{http.request.uri.path}/" + indexFile, indexFile} tryFiles = []string{"{http.request.uri.path}", "{http.request.uri.path}/" + indexFile, indexFile}
} else { } else {
longIndexPattern := "{http.request.uri.path}/" + indexFile longIndexPattern := "{http.request.uri.path}/" + indexFile
disableDirRedir = true
for _, tf := range tryFiles { for _, tf := range tryFiles {
if tf == longIndexPattern { if tf == longIndexPattern {
disableDirRedir = false
break break
} }
} }
disableDirRedir = true
} }
if !disableDirRedir { if !disableDirRedir {