mirror of
https://github.com/acepanel/panel.git
synced 2026-02-04 06:47:20 +08:00
fix: 部分情况下无法重命名文件
This commit is contained in:
@@ -217,7 +217,7 @@ func (s *FileService) Move(w http.ResponseWriter, r *http.Request) {
|
||||
continue
|
||||
}
|
||||
|
||||
if io.IsDir(item.Source) && strings.HasPrefix(item.Target, item.Source) {
|
||||
if io.IsDir(item.Source) && strings.HasPrefix(item.Target, item.Source+"/") {
|
||||
Error(w, http.StatusForbidden, s.t.Get("please don't do this"))
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user