diff --git a/CHANGELOG.md b/CHANGELOG.md index 90246cebd..afdbc8a79 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] (beta) ### Added +- Added OwnerName to the backup list json output. OwnerName holds either a UPN or a WebURL, depending on the resource type. + ### Fixed - Fix Exchange folder cache population error when parent folder isn't found. - Fix Exchange backup issue caused by incorrect json serialization diff --git a/src/pkg/backup/backup.go b/src/pkg/backup/backup.go index 352015203..d0796b58c 100644 --- a/src/pkg/backup/backup.go +++ b/src/pkg/backup/backup.go @@ -167,21 +167,23 @@ func PrintAll(ctx context.Context, bs []*Backup) { } type Printable struct { - ID model.StableID `json:"id"` - Status string `json:"status"` - Version string `json:"version"` - Owner string `json:"owner"` - Stats backupStats `json:"stats"` + ID model.StableID `json:"id"` + Status string `json:"status"` + Version string `json:"version"` + Owner string `json:"owner"` + OwnerName string `json:"ownerName"` + Stats backupStats `json:"stats"` } // ToPrintable reduces the Backup to its minimally printable details. func (b Backup) ToPrintable() Printable { return Printable{ - ID: b.ID, - Status: b.Status, - Version: "0", - Owner: b.Selector.DiscreteOwner, - Stats: b.toStats(), + ID: b.ID, + Status: b.Status, + Version: "0", + Owner: b.Selector.DiscreteOwner, + OwnerName: b.Selector.DiscreteOwnerName, + Stats: b.toStats(), } }