Skip to content

Commit 3dd80f5

Browse files
authored
PBM-1466 - Remove kingpin dependency from pbm cli (#1077)
* update to cobra * add conn close * disconnect and close with timeout
1 parent 8f3763f commit 3dd80f5

File tree

2 files changed

+850
-498
lines changed

2 files changed

+850
-498
lines changed

cmd/pbm/delete.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,10 @@ func deleteBackup(
3939
return nil, errors.New("either --name or --older-than should be set")
4040
}
4141
if d.name != "" && d.olderThan != "" {
42-
return nil, errors.New("cannot use --name and --older-then at the same command")
42+
return nil, errors.New("cannot use --name and --older-than at the same command")
4343
}
4444
if d.bcpType != "" && d.olderThan == "" {
45-
return nil, errors.New("cannot use --type without --older-then")
45+
return nil, errors.New("cannot use --type without --older-than")
4646
}
4747
if !d.dryRun {
4848
err := checkForAnotherOperation(ctx, pbm)
@@ -174,7 +174,7 @@ func deletePITR(
174174
return nil, errors.New("either --older-than or --all should be set")
175175
}
176176
if d.olderThan != "" && d.all {
177-
return nil, errors.New("cannot use --older-then and --all at the same command")
177+
return nil, errors.New("cannot use --older-than and --all at the same command")
178178
}
179179
if !d.dryRun {
180180
err := checkForAnotherOperation(ctx, pbm)
@@ -190,7 +190,7 @@ func deletePITR(
190190
var err error
191191
until, err = parseOlderThan(d.olderThan)
192192
if err != nil {
193-
return nil, errors.Wrap(err, "parse --older-then")
193+
return nil, errors.Wrap(err, "parse --older-than")
194194
}
195195

196196
now := time.Now().UTC()

0 commit comments

Comments
 (0)