From 5fde0798809546698cf2b2eb4aa95d0c6aa68815 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Wed, 6 May 2015 00:54:30 +0200 Subject: handleFree -> handle_free and so on... --- pyload/plugin/internal/MultiHoster.py | 12 ++++++------ pyload/plugin/internal/SimpleCrypter.py | 4 ++-- pyload/plugin/internal/SimpleHoster.py | 24 ++++++++++++------------ pyload/plugin/internal/XFSHoster.py | 8 ++++---- 4 files changed, 24 insertions(+), 24 deletions(-) (limited to 'pyload/plugin/internal') diff --git a/pyload/plugin/internal/MultiHoster.py b/pyload/plugin/internal/MultiHoster.py index 8dbcf4f30..06d78475b 100644 --- a/pyload/plugin/internal/MultiHoster.py +++ b/pyload/plugin/internal/MultiHoster.py @@ -61,7 +61,7 @@ class MultiHoster(SimpleHoster): if self.directDL: self.checkInfo() self.logDebug("Looking for direct download link...") - self.handleDirect(pyfile) + self.handle_direct(pyfile) if not self.link and not self.lastDownload: self.preload() @@ -71,11 +71,11 @@ class MultiHoster(SimpleHoster): if self.premium and (not self.CHECK_TRAFFIC or self.checkTrafficLeft()): self.logDebug("Handled as premium download") - self.handlePremium(pyfile) + self.handle_premium(pyfile) elif not self.LOGIN_ACCOUNT or (not self.CHECK_TRAFFIC or self.checkTrafficLeft()): self.logDebug("Handled as free download") - self.handleFree(pyfile) + self.handle_free(pyfile) self.downloadLink(self.link, True) self.checkFile() @@ -105,11 +105,11 @@ class MultiHoster(SimpleHoster): raise Fail(e) - def handlePremium(self, pyfile): - return self.handleFree(pyfile) + def handle_premium(self, pyfile): + return self.handle_free(pyfile) - def handleFree(self, pyfile): + def handle_free(self, pyfile): if self.premium: raise NotImplementedError else: diff --git a/pyload/plugin/internal/SimpleCrypter.py b/pyload/plugin/internal/SimpleCrypter.py index e22a4df29..dff543eed 100644 --- a/pyload/plugin/internal/SimpleCrypter.py +++ b/pyload/plugin/internal/SimpleCrypter.py @@ -94,7 +94,7 @@ class SimpleCrypter(Crypter, SimpleHoster): self.links = self.getLinks() if hasattr(self, 'PAGES_PATTERN') and hasattr(self, 'loadPage'): - self.handlePages(pyfile) + self.handle_pages(pyfile) self.logDebug("Package has %d links" % len(self.links)) @@ -142,7 +142,7 @@ class SimpleCrypter(Crypter, SimpleHoster): for link in re.findall(self.LINK_PATTERN, self.html)] - def handlePages(self, pyfile): + def handle_pages(self, pyfile): try: pages = int(re.search(self.PAGES_PATTERN, self.html).group(1)) except Exception: diff --git a/pyload/plugin/internal/SimpleHoster.py b/pyload/plugin/internal/SimpleHoster.py index d3e2edc48..7ba7db8da 100644 --- a/pyload/plugin/internal/SimpleHoster.py +++ b/pyload/plugin/internal/SimpleHoster.py @@ -287,7 +287,7 @@ class SimpleHoster(Hoster): example: ERROR_PATTERN = r'' - Instead overriding handleFree and handlePremium methods you can define the following patterns for direct download: + Instead overriding handle_free and handle_premium methods you can define the following patterns for direct download: LINK_FREE_PATTERN: (optional) group(1) should be the direct link for free download example: LINK_FREE_PATTERN = r'