mirror of
https://github.com/octoleo/restic.git
synced 2024-12-22 19:08:55 +00:00
Reenable cache
In 6341c7d72c
, the cache was accidentally
disabled due to a bug, this commit reenables the cache.
This commit is contained in:
parent
63bb1933e5
commit
ad82781743
@ -363,6 +363,9 @@ func OpenRepository(opts GlobalOptions) (*repository.Repository, error) {
|
|||||||
return s, nil
|
return s, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// start using the cache
|
||||||
|
s.UseCache(c)
|
||||||
|
|
||||||
oldCacheDirs, err := cache.Old(c.Base)
|
oldCacheDirs, err := cache.Old(c.Base)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
Warnf("unable to find old cache directories: %v", err)
|
Warnf("unable to find old cache directories: %v", err)
|
||||||
@ -389,7 +392,6 @@ func OpenRepository(opts GlobalOptions) (*repository.Repository, error) {
|
|||||||
len(oldCacheDirs), c.Base)
|
len(oldCacheDirs), c.Base)
|
||||||
}
|
}
|
||||||
|
|
||||||
s.UseCache(c)
|
|
||||||
return s, nil
|
return s, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user