aboutsummaryrefslogtreecommitdiff
path: root/connection.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'connection.cpp')
-rw-r--r--connection.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/connection.cpp b/connection.cpp
index c29f09fe..3e4f1efb 100644
--- a/connection.cpp
+++ b/connection.cpp
@@ -77,10 +77,9 @@ Connection::Connection(const QUrl& server, QObject* parent)
d->q = this; // All d initialization should occur before this line
}
-Connection::Connection()
- : Connection(QUrl("https://matrix.org"))
-{
-}
+Connection::Connection(QObject* parent)
+ : Connection({}, parent)
+{ }
Connection::~Connection()
{
@@ -165,6 +164,7 @@ void Connection::doConnectToServer(const QString& user, const QString& password,
deviceId, initialDeviceName);
connect(loginJob, &BaseJob::success, this,
[=] {
+ setHomeserver(loginJob->homeServer());
d->connectWithToken(loginJob->userId(), loginJob->accessToken(),
loginJob->deviceId());
});