aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/api.py
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2016-02-12 02:56:55 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2016-02-12 02:56:55 +0300
commitf9b481e688b6bc5ff8606910e1c0780cc01f05aa (patch)
treeee74548ae808a138dd59fcbb961cb7aa5f083641 /api.py
parentbugfix (diff)
downloadvk-scripts-f9b481e688b6bc5ff8606910e1c0780cc01f05aa.tar.gz
vk-scripts-f9b481e688b6bc5ff8606910e1c0780cc01f05aa.zip
request responses in English explicitly
Diffstat (limited to 'api.py')
-rw-r--r--api.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/api.py b/api.py
index 5d11e4f..e7fbb81 100644
--- a/api.py
+++ b/api.py
@@ -6,7 +6,7 @@ import json, sys, urllib.request
def call_method(method_name, **kwargs):
get_args = '&'.join(map(lambda k: '{}={}'.format(k, kwargs[k]), kwargs))
- url = 'https://api.vk.com/method/{}?{}'.format(method_name, get_args)
+ url = 'https://api.vk.com/method/{}?lang=en&{}'.format(method_name, get_args)
response = json.loads(urllib.request.urlopen(url).read().decode())
if 'response' not in response:
print(response, file=sys.stderr)