Преглед на файлове

Fixing the previous bug

Toby Chui преди 3 години
родител
ревизия
5663c0835f
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      mod/user/directoryHandler.go

+ 1 - 1
mod/user/directoryHandler.go

@@ -107,7 +107,7 @@ func (u *User) VirtualPathToRealPath(vpath string) (string, error) {
 
 			//A bit hacky to make sure subpath contains no traversal
 			//Will migrate this to File System Vpath Resolver in the next large update
-			subpath = strings.ReplaceAll(subpath, "..", "")
+			subpath = strings.ReplaceAll(subpath, "../", "")
 
 			//Handle general cases
 			if storage.Hierarchy == "user" {