From cdd1dc68daf6d4e3c69e7b6f9ee37707eb84eb5f Mon Sep 17 00:00:00 2001 From: fumiama Date: Mon, 29 Nov 2021 22:29:07 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=8F=EF=B8=8F=20=20=E4=BF=AE=E6=AD=A3=20?= =?UTF-8?q?=E6=9C=AC=E5=9C=B0=20setu=20=E6=8F=92=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugin_nativesetu/data.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugin_nativesetu/data.go b/plugin_nativesetu/data.go index 5d6cd932..4f217d82 100644 --- a/plugin_nativesetu/data.go +++ b/plugin_nativesetu/data.go @@ -6,6 +6,7 @@ import ( "io" "io/fs" "os" + "path/filepath" "sync" "github.com/corona10/goimagehash" @@ -63,7 +64,7 @@ func scanall(path string) error { root := os.DirFS(path) _ = db.Close() _ = os.Remove(dbfile) - return fs.WalkDir(root, ".", func(path string, d fs.DirEntry, err error) error { + return filepath.WalkDir(path, func(path string, d fs.DirEntry, err error) error { if err != nil { return err }