diff options
author | Walter Purcaro <vuolter@gmail.com> | 2014-10-26 02:31:54 +0200 |
---|---|---|
committer | Walter Purcaro <vuolter@gmail.com> | 2014-10-26 02:31:54 +0200 |
commit | 9f2ebe486a3e155fb6a60e07cccb77ab6a772eb2 (patch) | |
tree | 3b7b96651b12a2fb4765a3961a19bf3c67d4b64f /module/plugins/hoster/UploadingCom.py | |
parent | Avoid gettext conflict due variable `_` (diff) | |
download | pyload-9f2ebe486a3e155fb6a60e07cccb77ab6a772eb2.tar.xz |
Extend translation support in plugins + a lot of code cosmetics and typo fixes
Diffstat (limited to 'module/plugins/hoster/UploadingCom.py')
-rw-r--r-- | module/plugins/hoster/UploadingCom.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/module/plugins/hoster/UploadingCom.py b/module/plugins/hoster/UploadingCom.py index 71a1eb4a0..656543a83 100644 --- a/module/plugins/hoster/UploadingCom.py +++ b/module/plugins/hoster/UploadingCom.py @@ -56,7 +56,7 @@ class UploadingCom(SimpleHoster): url = url.group(1).replace("\\/", "/") self.download(url) - raise Exception("Plugin defect.") + raise Exception("Plugin defect") def handleFree(self): @@ -73,30 +73,30 @@ class UploadingCom(SimpleHoster): response = json_loads(self.load(ajax_url, post={'action': 'second_page', 'code': self.file_info['ID']})) if 'answer' in response and 'wait_time' in response['answer']: wait_time = int(response['answer']['wait_time']) - self.logInfo("%s: Waiting %d seconds." % (self.__name__, wait_time)) + self.logInfo(_("Waiting %d seconds") % wait_time) self.wait(wait_time) else: - self.error("AJAX/WAIT") + self.error(_("No AJAX/WAIT")) response = json_loads( self.load(ajax_url, post={'action': 'get_link', 'code': self.file_info['ID'], 'pass': 'false'})) if 'answer' in response and 'link' in response['answer']: url = response['answer']['link'] else: - self.error("AJAX/URL") + self.error(_("No AJAX/URL")) self.html = self.load(url) m = re.search(r'<form id="file_form" action="(.*?)"', self.html) if m: url = m.group(1) else: - self.error("URL") + self.error(_("No URL")) self.download(url) check = self.checkDownload({"html": re.compile("\A<!DOCTYPE html PUBLIC")}) if check == "html": - self.logWarning("Redirected to a HTML page, wait 10 minutes and retry") + self.logWarning(_("Redirected to a HTML page, wait 10 minutes and retry")) self.wait(10 * 60, True) |