minor fix

This commit is contained in:
wilsongomez 2022-10-14 16:03:34 -05:00
parent 5d247e72fd
commit 859122139f
1 changed files with 2 additions and 0 deletions

View File

@ -405,6 +405,8 @@ class MercadoLibre(SaleWebChannel):
response = requests.post(uri, params=urlencode(params),
headers=HEADERS, data=params)
res = response.json()
if res.get('error', None):
raise UserError(res.get('message') + ' Error:' + res.get('error'))
return res['access_token'], res['refresh_token']
@classmethod