This commit is contained in:
Adriane Boyd 2022-11-03 12:43:50 +01:00
parent 0c51c2c698
commit 25d56ce0f7

View File

@ -93,7 +93,9 @@ class RemoteStorage:
return prefix == abs_directory
def safe_extract(tar, path=".", members=None, *, numeric_owner=False):
def safe_extract(
tar, path=".", members=None, *, numeric_owner=False
):
for member in tar.getmembers():
member_path = os.path.join(path, member.name)
@ -102,7 +104,6 @@ class RemoteStorage:
tar.extractall(path, members, numeric_owner=numeric_owner)
safe_extract(tar_file, self.root)
return url