mirror of
https://github.com/FloatTech/ZeroBot-Plugin.git
synced 2025-12-19 13:59:39 +08:00
✏️ 修正 本地 setu 插件
This commit is contained in:
parent
37af3c1498
commit
cdd1dc68da
@ -6,6 +6,7 @@ import (
|
|||||||
"io"
|
"io"
|
||||||
"io/fs"
|
"io/fs"
|
||||||
"os"
|
"os"
|
||||||
|
"path/filepath"
|
||||||
"sync"
|
"sync"
|
||||||
|
|
||||||
"github.com/corona10/goimagehash"
|
"github.com/corona10/goimagehash"
|
||||||
@ -63,7 +64,7 @@ func scanall(path string) error {
|
|||||||
root := os.DirFS(path)
|
root := os.DirFS(path)
|
||||||
_ = db.Close()
|
_ = db.Close()
|
||||||
_ = os.Remove(dbfile)
|
_ = 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 {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user