Skip to content

Commit

Permalink
Log the correct snapshot ID (#1030)
Browse files Browse the repository at this point in the history
  • Loading branch information
pavannd1 committed Jun 19, 2021
1 parent 8274ba4 commit 00110b8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/kopia/snapshot.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func SnapshotSource(
sourceInfo snapshot.SourceInfo,
rootDir fs.Entry,
description string,
) (snapID string, snapSize int64, err error) {
) (string, int64, error) {
fmt.Printf("Snapshotting %v ...\n", sourceInfo)

t0 := time.Now()
Expand Down Expand Up @@ -76,9 +76,9 @@ func SnapshotSource(
return "", 0, errors.Wrap(ferr, "Failed to flush kopia repository")
}

snapSize = manifest.Stats.TotalFileSize
snapSize := manifest.Stats.TotalFileSize

fmt.Printf("\nCreated snapshot with root %v and ID %v in %v\n", manifest.RootObjectID(), snapID, time.Since(t0).Truncate(time.Second))
fmt.Printf("\nCreated snapshot with root %v and ID %v in %v\n", manifest.RootObjectID(), manifestID, time.Since(t0).Truncate(time.Second))

return string(manifestID), snapSize, nil
}
Expand Down

0 comments on commit 00110b8

Please sign in to comment.