Raise IncorrectSessionTokenException instead of returning it
@@ -0,0 +1 @@
+Fix a bug in the error handling of 3PID session validation, if the token submitted is incorrect.
@@ -64,4 +64,4 @@ def validateSessionWithToken(sydent, sid, clientSecret, token):
return {'success': True}
else:
logger.info("Incorrect token submitted")
- return IncorrectSessionTokenException()
+ raise IncorrectSessionTokenException()