mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-10-15 20:06:19 +08:00
fix filename not set error
This commit is contained in:
@@ -165,7 +165,7 @@ func GetOrHeadHandler(w http.ResponseWriter, r *http.Request, isGetMethod bool)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if n.NameSize > 0 && filename == "" {
|
if n.NameSize > 0 && filename == "" {
|
||||||
filename := string(n.Name)
|
filename = string(n.Name)
|
||||||
dotIndex := strings.LastIndex(filename, ".")
|
dotIndex := strings.LastIndex(filename, ".")
|
||||||
if dotIndex > 0 {
|
if dotIndex > 0 {
|
||||||
ext = filename[dotIndex:]
|
ext = filename[dotIndex:]
|
||||||
|
Reference in New Issue
Block a user