Skip to content

Commit

Permalink
update input param in create_token() when linking
Browse files Browse the repository at this point in the history
this needs updating from u to user because there is no longer u at this point
  • Loading branch information
stuzl committed Feb 29, 2016
1 parent dda7cfb commit 3491af7
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions examples/server/python/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def facebook():
user.facebook = profile['id']
user.display_name = user.display_name or profile['name']
db.session.commit()
token = create_token(u)
token = create_token(user)
return jsonify(token=token)

# Step 4. Create a new account or return an existing one.
Expand Down Expand Up @@ -241,7 +241,7 @@ def github():
user.github = profile['id']
user.display_name = display_name or profile['name']
db.session.commit()
token = create_token(u)
token = create_token(user)
return jsonify(token=token)

# Step 4. Create a new account or return an existing one.
Expand Down Expand Up @@ -296,7 +296,7 @@ def google():
user.google = profile['sub']
user.display_name = user.display_name or profile['name']
db.session.commit()
token = create_token(u)
token = create_token(user)
return jsonify(token=token)

# Step 4. Create a new account or return an existing one.
Expand Down Expand Up @@ -352,7 +352,7 @@ def linkedin():
user.linkedin = profile['id']
user.display_name = user.display_name or (profile['firstName'] + ' ' + profile['lastName'])
db.session.commit()
token = create_token(u)
token = create_token(user)
return jsonify(token=token)

# Step 4. Create a new account or return an existing one.
Expand Down Expand Up @@ -442,7 +442,7 @@ def bitbucket():
user.bitbucket = profile['uuid']
user.display_name = user.display_name or profile['display_name']
db.session.commit()
token = create_token(u)
token = create_token(user)
return jsonify(token=token)

# Step 4. Create a new account or return an existing one.
Expand Down

0 comments on commit 3491af7

Please sign in to comment.