0
0
mirror of https://github.com/ihabunek/toot.git synced 2025-09-21 19:35:03 -04:00

Make verify_credentials return the http response

Required if we want to emit json without decoding it
This commit is contained in:
Ivan Habunek
2023-11-18 14:55:45 +01:00
parent 317840b019
commit 6cdba16fcf
5 changed files with 22 additions and 43 deletions

View File

@@ -66,7 +66,7 @@ def get_instance_domain(base_url):
def create_user(app, access_token):
# Username is not yet known at this point, so fetch it from Mastodon
user = User(app.instance, None, access_token)
creds = api.verify_credentials(app, user)
creds = api.verify_credentials(app, user).json()
user = User(app.instance, creds['username'], access_token)
config.save_user(user, activate=True)