-
Notifications
You must be signed in to change notification settings - Fork 79
Open
Description
Hi, thanks for your image.
I've tried to use the custom headers feature. They work for files, but not for directories, although requesting a directory leads to its index.html. To be more precise, a config entry with "path": "*", "fileExtension": "html" does apply when requesting /path/index.html, but does not for /path, although the response body is the same.
The code at
Line 88 in 131f492
| reqFileExtension := filepath.Ext(r.URL.Path) |
As a side note, I believe path + fileExtension should be superseded by a path glob or a regex, which is more powerful, and is actually not more complex. For instance, a rule with glob /**/ or regex \/$ would apply to any directory, and a rule with glob /**/*.css (or maybe even *.css) or regex \.css$ would apply to any CSS file.
phartenfeller and alex-tan
Metadata
Metadata
Assignees
Labels
No labels