fix(Backup): automatically rollback decryption when object is being deleted

This allows us to not have to call it everytime before returning

Signed-off-by: Akhil Narang <me@akhilnarang.dev>
This commit is contained in:
Akhil Narang 2023-10-26 15:35:16 +05:30
parent 3b0f6de883
commit cb7c0e653c
No known key found for this signature in database
GPG key ID: 9DCC61E211BF645F

View file

@ -670,6 +670,9 @@ class Backup:
os.remove(self.file_path.rstrip(".gz"))
os.rename(self.file_path + ".gpg", self.file_path)
def __del__(self):
self.decryption_rollback()
def backup(
with_files=False,