client/server rebuilding in progress

This commit is contained in:
2026-03-04 17:15:06 +02:00
parent ae9c29de1e
commit 36a143c7c3
14 changed files with 781 additions and 1249 deletions
+3 -6
View File
@@ -124,7 +124,7 @@ func (store *Storage) HardlinkFile(tmpname, collection, filename string) error {
}
filename = store.makeFilepath(collection, filename)
os.Remove(filename) // TODO
os.Remove(filename) // TODO: safe removing
tmpname = store.makeTmppath(tmpname)
err = os.Link(tmpname, filename)
@@ -145,12 +145,9 @@ func (store *Storage) DeleteFile(collection, filename string) error {
if err != nil {
return err
}
// TODO: safe dir removing
// TODO: clean removing
dirname := store.makeCollecionpath(collection)
err = os.RemoveAll(dirname)
if err != nil {
return err
}
os.RemoveAll(dirname)
return err
}