mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2025-03-16 12:25:45 +01:00
request.py: fix for python2.7
This commit is contained in:
parent
26f87c4873
commit
ccb24d1288
1 changed files with 1 additions and 3 deletions
|
@ -170,9 +170,7 @@ def post(url,
|
|||
data=data.encode(),
|
||||
headers={'Content-Type': 'application/json'})
|
||||
|
||||
with urlopen(request, **urlopen_kwargs) as handle:
|
||||
result = handle.read()
|
||||
|
||||
result = urlopen(request, **urlopen_kwargs).read()
|
||||
return _parse(result)
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue