Merge 040a2c3e00708c9d3bbf2c5c5bcd8b37a7a70d16 into ef68fa032c0e6ce637db56e89ec734c0de0a9f5e

This commit is contained in:
Kiyan 2025-05-15 09:13:43 +02:00 committed by GitHub
commit 8276fad8de
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -224,7 +224,7 @@ func (group *RouterGroup) createStaticHandler(relativePath string, fs http.FileS
file := c.Param("filepath")
// Check if file exists and/or if we have permission to access it
f, err := fs.Open(file)
f, err := fs.Open(path.Clean(file))
if err != nil {
c.Writer.WriteHeader(http.StatusNotFound)
c.handlers = group.engine.noRoute