summaryrefslogtreecommitdiffstats
path: root/module/plugins/Crypter.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-11-01 18:47:26 +0100
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-11-01 18:47:26 +0100
commit92d05c08633474af06ff5682468e7e5cf5c2f91b (patch)
tree6cb0174bc4be49c70b45af04043a2d3b78952a97 /module/plugins/Crypter.py
parent[Plugin] Declare self.html as empty string, not as None type (diff)
downloadpyload-92d05c08633474af06ff5682468e7e5cf5c2f91b.tar.xz
[Crypter] Fix config handling
Diffstat (limited to 'module/plugins/Crypter.py')
-rw-r--r--module/plugins/Crypter.py13
1 files changed, 9 insertions, 4 deletions
diff --git a/module/plugins/Crypter.py b/module/plugins/Crypter.py
index 87bde124b..e7148e11f 100644
--- a/module/plugins/Crypter.py
+++ b/module/plugins/Crypter.py
@@ -7,7 +7,7 @@ from module.utils import save_path
class Crypter(Plugin):
__name__ = "Crypter"
__type__ = "crypter"
- __version__ = "0.3"
+ __version__ = "0.4"
__pattern__ = None
__config__ = [("use_subfolder", "bool", "Save package to subfolder", True), #: Overrides core.config['general']['folder_per_package']
@@ -59,10 +59,15 @@ class Crypter(Plugin):
package_password = self.pyfile.package().password
package_queue = self.pyfile.package().queue
- use_subfolder = self.getConfig('use_subfolder')
- subfolder_per_package = self.getConfig('subfolder_per_package')
-
folder_per_package = self.config['general']['folder_per_package']
+ try:
+ use_subfolder = self.getConfig('use_subfolder')
+ except:
+ use_subfolder = folder_per_package
+ try:
+ subfolder_per_package = self.getConfig('subfolder_per_package')
+ except:
+ subfolder_per_package = True
for pack in self.packages:
name, links, folder = pack