summaryrefslogtreecommitdiffstats
path: root/module/plugins/hoster/LetitbitNet.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@gmail.com> 2014-12-31 00:08:37 +0100
committerGravatar Walter Purcaro <vuolter@gmail.com> 2014-12-31 00:08:37 +0100
commitdbab8fd6cda68f2650e97a5d68a055c4424cd3a4 (patch)
treed5233ffb0f4bb295bf775c30f920c32fa13d4062 /module/plugins/hoster/LetitbitNet.py
parentHandle methods get pyfile argument (diff)
downloadpyload-dbab8fd6cda68f2650e97a5d68a055c4424cd3a4.tar.xz
[LetitbitNet] Use getURL instead urlopen
Diffstat (limited to 'module/plugins/hoster/LetitbitNet.py')
-rw-r--r--module/plugins/hoster/LetitbitNet.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/module/plugins/hoster/LetitbitNet.py b/module/plugins/hoster/LetitbitNet.py
index a7b11047f..f3921fdb7 100644
--- a/module/plugins/hoster/LetitbitNet.py
+++ b/module/plugins/hoster/LetitbitNet.py
@@ -8,18 +8,18 @@
import re
-from urllib import urlencode, urlopen
from urlparse import urljoin
from module.common.json_layer import json_loads, json_dumps
+from module.network.RequestFactory import getURL
from module.plugins.internal.CaptchaService import ReCaptcha
from module.plugins.internal.SimpleHoster import SimpleHoster, secondsToMidnight
def api_download_info(url):
json_data = ["yw7XQy2v9", ["download/info", {"link": url}]]
- post_data = urlencode({'r': json_dumps(json_data)})
- api_rep = urlopen("http://api.letitbit.net/json", data=post_data).read()
+ api_rep = getURL("http://api.letitbit.net/json",
+ post={'r': json_dumps(json_data)})
return json_loads(api_rep)
@@ -36,7 +36,7 @@ def getInfo(urls):
class LetitbitNet(SimpleHoster):
__name__ = "LetitbitNet"
__type__ = "hoster"
- __version__ = "0.27"
+ __version__ = "0.28"
__pattern__ = r'https?://(?:www\.)?(letitbit|shareflare)\.net/download/.+'