mirror of
https://github.com/restic/restic.git
synced 2025-10-09 13:49:58 +00:00
repository: extract Load/StoreJSONUnpacked
A Load/Store method for each data type is much clearer. As a result the repository no longer needs a method to load / store json.
This commit is contained in:
@@ -68,7 +68,7 @@ func (*UpgradeRepoV2) upgrade(ctx context.Context, repo restic.Repository) error
|
||||
cfg := repo.Config()
|
||||
cfg.Version = 2
|
||||
|
||||
_, err := repo.SaveJSONUnpacked(ctx, restic.ConfigFile, cfg)
|
||||
err := restic.SaveConfig(ctx, repo, cfg)
|
||||
if err != nil {
|
||||
return fmt.Errorf("save new config file failed: %w", err)
|
||||
}
|
||||
|
Reference in New Issue
Block a user