mirror of
https://github.com/restic/restic.git
synced 2024-07-04 09:00:54 +02:00
s3: don't remove the bucket on Delete()
This commit is contained in:
parent
55f10eb1c1
commit
248f991ad4
|
@ -240,7 +240,7 @@ func (be *S3Backend) removeKeys(t backend.Type) error {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// Delete removes all restic keys and the bucket.
|
// Delete removes all restic keys in the bucket. It will not remove the bucket itself.
|
||||||
func (be *S3Backend) Delete() error {
|
func (be *S3Backend) Delete() error {
|
||||||
alltypes := []backend.Type{
|
alltypes := []backend.Type{
|
||||||
backend.Data,
|
backend.Data,
|
||||||
|
@ -256,12 +256,7 @@ func (be *S3Backend) Delete() error {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
err := be.Remove(backend.Config, "")
|
return be.Remove(backend.Config, "")
|
||||||
if err != nil {
|
|
||||||
return err
|
|
||||||
}
|
|
||||||
|
|
||||||
return be.s3api.RemoveBucket(be.bucketname)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Close does nothing
|
// Close does nothing
|
||||||
|
|
Loading…
Reference in New Issue
Block a user