From f607cb27027d0f5180ac69b7a040672502912ca2 Mon Sep 17 00:00:00 2001 From: Travis Ralston Date: Thu, 1 Nov 2018 17:55:48 -0600 Subject: [PATCH] Fix the registration process to handle m.login.terms auth --- src/usecases/signup.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/usecases/signup.js b/src/usecases/signup.js index b715e111a1..dfd97a975f 100644 --- a/src/usecases/signup.js +++ b/src/usecases/signup.js @@ -59,6 +59,12 @@ module.exports = async function signup(session, username, password, homeserver) //confirm dialog saying you cant log back in without e-mail const continueButton = await session.waitAndQuery('.mx_QuestionDialog button.mx_Dialog_primary'); await continueButton.click(); + + //find the privacy policy checkbox and check it + //this should automatically move ahead with registration + const policyCheckbox = await session.waitAndQuery('.mx_Login_box input[type="checkbox"]'); + await policyCheckbox.click(); + //wait for registration to finish so the hash gets set //onhashchange better? await session.delay(2000);