From 23006e495ffa31e5cd2161f593bff4d1c3e6fe80 Mon Sep 17 00:00:00 2001 From: shortcutme Date: Tue, 19 Nov 2019 01:45:50 +0100 Subject: [PATCH] FilePack plugin pass possible other parameters to site storage read function --- plugins/FilePack/FilePackPlugin.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/FilePack/FilePackPlugin.py b/plugins/FilePack/FilePackPlugin.py index 840961b7..e4a2dd8e 100644 --- a/plugins/FilePack/FilePackPlugin.py +++ b/plugins/FilePack/FilePackPlugin.py @@ -179,7 +179,7 @@ class SiteStoragePlugin(object): else: return super(SiteStoragePlugin, self).list(inner_path, *args, **kwags) - def read(self, inner_path, mode="rb"): + def read(self, inner_path, mode="rb", **kwargs): if ".zip/" in inner_path or ".tar.gz/" in inner_path: match = re.match("^(.*\.(?:tar.gz|tar.bz2|zip))(.*)", inner_path) archive_inner_path, path_within = match.groups() @@ -192,5 +192,5 @@ class SiteStoragePlugin(object): return archive.extractfile(path_within).read() else: - return super(SiteStoragePlugin, self).read(inner_path, mode) + return super(SiteStoragePlugin, self).read(inner_path, mode, **kwargs)