Skip to content

Commit

Permalink
Merge pull request #296 from matrix-org/babolivier/return_raise
Browse files Browse the repository at this point in the history
Raise IncorrectSessionTokenException instead of returning it
  • Loading branch information
babolivier committed May 28, 2020
2 parents 6453fcb + 0a90ad4 commit a005037
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelog.d/296.bugfix
@@ -0,0 +1 @@
Fix a bug in the error handling of 3PID session validation, if the token submitted is incorrect.
2 changes: 1 addition & 1 deletion sydent/validators/common.py
Expand Up @@ -64,4 +64,4 @@ def validateSessionWithToken(sydent, sid, clientSecret, token):
return {'success': True}
else:
logger.info("Incorrect token submitted")
return IncorrectSessionTokenException()
raise IncorrectSessionTokenException()

0 comments on commit a005037

Please sign in to comment.