mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-12-23 11:35:04 +01:00
Parse loginToken from query parameter
Signed-off-by: RMidhunSuresh <rmidhunsuresh@gmail.com>
This commit is contained in:
parent
18e1c305f5
commit
19664e54be
@ -152,6 +152,10 @@ export function parseUrlPath(urlPath, currentNavPath, defaultSessionId) {
|
|||||||
const userId = iterator.next().value;
|
const userId = iterator.next().value;
|
||||||
if (!userId) { break; }
|
if (!userId) { break; }
|
||||||
pushRightPanelSegment(segments, type, userId);
|
pushRightPanelSegment(segments, type, userId);
|
||||||
|
} else if (type.includes("loginToken")) {
|
||||||
|
// Special case for SSO-login with query parameter loginToken=<token>
|
||||||
|
const loginToken = type.split("=").pop();
|
||||||
|
segments.push(new Segment("sso", loginToken));
|
||||||
} else {
|
} else {
|
||||||
// might be undefined, which will be turned into true by Segment
|
// might be undefined, which will be turned into true by Segment
|
||||||
const value = iterator.next().value;
|
const value = iterator.next().value;
|
||||||
|
Loading…
Reference in New Issue
Block a user