mirror of
https://github.com/janLo/wallabag-kindle-consumer
synced 2026-06-19 19:08:00 +00:00
Sending Username and Password in HTTP POST request
This commit is contained in:
@@ -45,7 +45,7 @@ class Wallabag:
|
||||
'password': passwd}
|
||||
|
||||
async with aiohttp.ClientSession() as session:
|
||||
async with session.get(self._url('/oauth/v2/token'), params=params) as resp:
|
||||
async with session.post(self._url('/oauth/v2/token'), json=params) as resp:
|
||||
if resp.status != 200:
|
||||
logger.warn("Cannot get token for user {user}", user=user.name)
|
||||
return False
|
||||
@@ -65,7 +65,7 @@ class Wallabag:
|
||||
'username': user.name}
|
||||
|
||||
async with aiohttp.ClientSession() as session:
|
||||
async with session.get(self._url('/oauth/v2/token'), params=params) as resp:
|
||||
async with session.post(self._url('/oauth/v2/token'), json=params) as resp:
|
||||
if resp.status != 200:
|
||||
logger.warn("Cannot refresh token for user {user}", user=user.name)
|
||||
return False
|
||||
|
||||
Reference in New Issue
Block a user