Skip to content

Commit

Permalink
added print statements
Browse files Browse the repository at this point in the history
  • Loading branch information
rohit13k committed Oct 28, 2019
1 parent f9bf24f commit 05f644f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion apps/backend/api/v0/oauth2_routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,8 @@ def login_with_iot_callback():
data2 = ImmutableMultiDict([('grant_type', 'password'), ('username', session_token),
('scope', 'profile'), ('password', 'dummy')])
request.form = data2
print("request data created.")


# Get personal data
name = ""
Expand All @@ -246,9 +248,11 @@ def login_with_iot_callback():
area = districts[profile_data['value']]

User.update_user(session_token, name, city, age, area)
print("User updated")
User.user_add_community(session_token, bcn_community_obj.id)

print("User added to community")
token = authorization.create_token_response(request)
print("token created")
return token
else:
response = jsonify(message="Invalid Token")
Expand Down

0 comments on commit 05f644f

Please sign in to comment.