chore: finish remaining os.RemoveAll safety checks
Some checks failed
Automated Container Build / build-and-push (push) Failing after 1m13s

This commit is contained in:
Elijah 2026-05-26 13:32:32 -07:00
parent 701766b611
commit 109c602692

View file

@ -457,7 +457,7 @@ func (h *FSHandler) Move(c *fiber.Ctx) error {
dstFull = filepath.Join(parentDir, uniqueName)
body.DestPath = filepath.Join(filepath.Dir(body.DestPath), uniqueName)
} else {
os.RemoveAll(dstFull)
safeRemovePath(h.Config.StorageDir, dstFull)
}
}
@ -515,7 +515,7 @@ func (h *FSHandler) Copy(c *fiber.Ctx) error {
uniqueName := GetUniquePath(parentDir, filepath.Base(dstFull))
finalDst = filepath.Join(parentDir, uniqueName)
} else {
os.RemoveAll(dstFull)
safeRemovePath(h.Config.StorageDir, dstFull)
}
}