summaryrefslogtreecommitdiffstats
path: root/module/plugins/hooks/UserAgentSwitcher.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-12-14 03:44:18 +0100
committerGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-12-27 20:53:53 +0100
commit48c743058bd280d62d2aa9f2db56d894b502a8d9 (patch)
treec7134030736d3361463bfa92cf06979dcdab2ceb /module/plugins/hooks/UserAgentSwitcher.py
parentRename IRC and XMPP addon plugins (diff)
downloadpyload-48c743058bd280d62d2aa9f2db56d894b502a8d9.tar.xz
Update addons
Diffstat (limited to 'module/plugins/hooks/UserAgentSwitcher.py')
-rw-r--r--module/plugins/hooks/UserAgentSwitcher.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/module/plugins/hooks/UserAgentSwitcher.py b/module/plugins/hooks/UserAgentSwitcher.py
index 402dd001d..4b0b13c93 100644
--- a/module/plugins/hooks/UserAgentSwitcher.py
+++ b/module/plugins/hooks/UserAgentSwitcher.py
@@ -3,13 +3,13 @@
import pycurl
from module.plugins.internal.Addon import Addon
-from module.plugins.internal.utils import encode
+from module.plugins.internal.misc import encode
class UserAgentSwitcher(Addon):
__name__ = "UserAgentSwitcher"
__type__ = "hook"
- __version__ = "0.12"
+ __version__ = "0.13"
__status__ = "testing"
__config__ = [("activated" , "bool", "Activated" , True ),
@@ -23,9 +23,9 @@ class UserAgentSwitcher(Addon):
def download_preparing(self, pyfile):
- connecttimeout = self.get_config('connecttimeout')
- maxredirs = self.get_config('maxredirs')
- useragent = self.get_config('useragent')
+ connecttimeout = self.config.get('connecttimeout')
+ maxredirs = self.config.get('maxredirs')
+ useragent = self.config.get('useragent')
if connecttimeout:
pyfile.plugin.req.http.c.setopt(pycurl.CONNECTTIMEOUT, connecttimeout)