mirror of
https://github.com/restic/restic.git
synced 2026-11-06 07:19:21 +00:00
fs: unexport Local and expose via NewLocal
This commit is contained in:
1 parent
1acc19dac5
commit
e1e7fc8fb2
20 files changed
+72
-67
No files matched your search
@@ -489,7 +489,7 @@ func (res *Restorer) removeUnexpectedFiles(ctx context.Context, target, location
|
||||
panic("internal error")
|
||||
}
|
||||
|
||||
entries, err := fs.Readdirnames(fs.Local{}, target, fs.O_NOFOLLOW)
|
||||
entries, err := fs.Readdirnames(fs.NewLocal(), target, fs.O_NOFOLLOW)
|
||||
if errors.Is(err, os.ErrNotExist) {
|
||||
return nil
|
||||
} else if err != nil {
|
||||
|
||||
@@ -1537,7 +1537,7 @@ func TestRestorerLongPath(t *testing.T) {
|
||||
|
||||
repo := repository.TestRepository(t)
|
||||
|
||||
local := &fs.Local{}
|
||||
local := fs.NewLocal()
|
||||
sc := archiver.NewScanner(local)
|
||||
rtest.OK(t, sc.Scan(context.TODO(), []string{tmp}))
|
||||
arch := archiver.New(repo, local, archiver.Options{})
|
||||
|
||||
Reference in new issue
Block a user