mirror of
https://github.com/restic/restic.git
synced 2026-11-23 05:42:39 +00:00
backend: remove Test method
The Test method was only used in exactly one place, namely when trying to create a new repository it was used to check whether a config file already exists. Use a combination of Stat() and IsNotExist() instead.
This commit is contained in:
1 parent
57d8eedb88
commit
40ac678252
24 files changed
+47
-230
No files matched your search
@@ -1873,10 +1873,6 @@ type noCancelBackend struct {
|
||||
restic.Backend
|
||||
}
|
||||
|
||||
func (c *noCancelBackend) Test(ctx context.Context, h restic.Handle) (bool, error) {
|
||||
return c.Backend.Test(context.Background(), h)
|
||||
}
|
||||
|
||||
func (c *noCancelBackend) Remove(ctx context.Context, h restic.Handle) error {
|
||||
return c.Backend.Remove(context.Background(), h)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user