From 401d18bcc622d1a77bcb9ff16fc7cc3c2f24ad89 Mon Sep 17 00:00:00 2001 From: David Baker Date: Thu, 28 Jan 2016 15:42:14 +0000 Subject: [PATCH] Fix registration: don't auto-log in as a guest if we have a URL from sydent. --- src/components/structures/MatrixChat.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/components/structures/MatrixChat.js b/src/components/structures/MatrixChat.js index bf4258d990..e0f8ab96b3 100644 --- a/src/components/structures/MatrixChat.js +++ b/src/components/structures/MatrixChat.js @@ -100,6 +100,10 @@ module.exports = React.createClass({ console.log("Not registering as guest; email invite."); this._autoRegisterAsGuest = false; } + else if (this.props.startingQueryParams.client_secret && this.props.startingQueryParams.sid) { + console.log("Not registering as guest; registration."); + this._autoRegisterAsGuest = false; + } else { this._autoRegisterAsGuest = true; }