Ask for consent to terms and conditions if required

This commit is contained in:
Tobias Fella
2020-12-30 13:17:14 +00:00
committed by Carl Schwan
parent 45c35b3cbe
commit 0c449ab4bd
3 changed files with 37 additions and 1 deletions

View File

@@ -231,6 +231,12 @@ void Controller::addConnection(Connection *c)
dropConnection(c);
});
connect(c, &Connection::requestFailed, this, [=] (BaseJob *job) {
if(job->error() == BaseJob::UserConsentRequiredError) {
Q_EMIT userConsentRequired(job->errorUrl());
}
});
setBusy(true);
c->sync();

View File

@@ -113,6 +113,7 @@ Q_SIGNALS:
void passwordStatus(Controller::PasswordStatus _t1);
void showWindow();
void openRoom(NeoChatRoom *room);
void userConsentRequired(QUrl url);
public Q_SLOTS:
void logout(Quotient::Connection *conn, bool serverSideLogout);