mirror of
https://github.com/restic/restic.git
synced 2025-12-03 21:21:47 +00:00
Stop Counters where they're constructed and started
This commit is contained in:
@@ -51,8 +51,6 @@ type Lister interface {
|
||||
// New creates a new index for repo from scratch. InvalidFiles contains all IDs
|
||||
// of files that cannot be listed successfully.
|
||||
func New(ctx context.Context, repo Lister, ignorePacks restic.IDSet, p *progress.Counter) (idx *Index, invalidFiles restic.IDs, err error) {
|
||||
defer p.Done()
|
||||
|
||||
type Job struct {
|
||||
PackID restic.ID
|
||||
Size int64
|
||||
@@ -191,8 +189,6 @@ func loadIndexJSON(ctx context.Context, repo ListLoader, id restic.ID) (*indexJS
|
||||
func Load(ctx context.Context, repo ListLoader, p *progress.Counter) (*Index, error) {
|
||||
debug.Log("loading indexes")
|
||||
|
||||
defer p.Done()
|
||||
|
||||
supersedes := make(map[restic.ID]restic.IDSet)
|
||||
results := make(map[restic.ID]map[restic.ID]Pack)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user