From 98ef1d64e703c2a97fe1eee55debe5d976ba9cf5 Mon Sep 17 00:00:00 2001 From: Mickael Kerjean Date: Thu, 3 Nov 2022 00:12:09 +1100 Subject: [PATCH] fix (fs): recursive removal in local and tmp backend --- server/plugin/plg_backend_local/index.go | 2 +- server/plugin/plg_backend_tmp/index.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/server/plugin/plg_backend_local/index.go b/server/plugin/plg_backend_local/index.go index 1975480d..884096cd 100644 --- a/server/plugin/plg_backend_local/index.go +++ b/server/plugin/plg_backend_local/index.go @@ -66,7 +66,7 @@ func (this Local) Mkdir(path string) error { } func (this Local) Rm(path string) error { - return SafeOsRemove(path) + return SafeOsRemoveAll(path) } func (this Local) Mv(from, to string) error { diff --git a/server/plugin/plg_backend_tmp/index.go b/server/plugin/plg_backend_tmp/index.go index 89af8c6d..d8dbd6f4 100644 --- a/server/plugin/plg_backend_tmp/index.go +++ b/server/plugin/plg_backend_tmp/index.go @@ -114,7 +114,7 @@ func (this TmpStorage) Rm(path string) error { if err := this.VerifyPath(path); err != nil { return err } - return SafeOsRemove(path) + return SafeOsRemoveAll(path) } func (this TmpStorage) Mv(from, to string) error {