From 4cd693b5c4f2ede4ac4928b5b433b3932d64519a Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sun, 7 Sep 2014 23:50:03 +0200 Subject: save_join -> safe_join & save_path -> safe_filename --- module/plugins/Container.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'module/plugins/Container.py') diff --git a/module/plugins/Container.py b/module/plugins/Container.py index 63804d713..59efbd8dd 100644 --- a/module/plugins/Container.py +++ b/module/plugins/Container.py @@ -6,7 +6,7 @@ from os import remove from os.path import basename, exists from module.plugins.Crypter import Crypter -from module.utils import save_join +from module.utils import safe_join class Container(Crypter): @@ -42,7 +42,7 @@ class Container(Crypter): if self.pyfile.url.startswith("http"): self.pyfile.name = re.findall("([^\/=]+)", self.pyfile.url)[-1] content = self.load(self.pyfile.url) - self.pyfile.url = save_join(self.config['general']['download_folder'], self.pyfile.name) + self.pyfile.url = safe_join(self.config['general']['download_folder'], self.pyfile.name) f = open(self.pyfile.url, "wb" ) f.write(content) f.close() @@ -50,8 +50,8 @@ class Container(Crypter): else: self.pyfile.name = basename(self.pyfile.url) if not exists(self.pyfile.url): - if exists(save_join(pypath, self.pyfile.url)): - self.pyfile.url = save_join(pypath, self.pyfile.url) + if exists(safe_join(pypath, self.pyfile.url)): + self.pyfile.url = safe_join(pypath, self.pyfile.url) else: self.fail(_("File not exists.")) -- cgit v1.2.3