Restore confirmation to delete -r, lost in botched merge
This commit is contained in:
parent
6ac8a0ad88
commit
747d7e7173
1 changed files with 13 additions and 0 deletions
|
|
@ -162,6 +162,19 @@ func deleteByRepo(log *output.Logger, repo string, force bool) error {
|
|||
if !strings.EqualFold(c.RepositoryNWO, repo) {
|
||||
continue
|
||||
}
|
||||
|
||||
confirmed, err := confirmDeletion(c, force)
|
||||
if err != nil {
|
||||
mu.Lock()
|
||||
errs = append(errs, fmt.Errorf("deletion could not be confirmed: %w", err))
|
||||
mu.Unlock()
|
||||
continue
|
||||
}
|
||||
|
||||
if !confirmed {
|
||||
continue
|
||||
}
|
||||
|
||||
found = true
|
||||
c := c
|
||||
wg.Add(1)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue