From bac5fa8c14910365c09fc8a4a0ad5bbd79716d69 Mon Sep 17 00:00:00 2001 From: Tobias Fella Date: Tue, 20 Feb 2024 18:19:49 +0100 Subject: [PATCH] Don't try setting up push notifications when there's no endpoint --- src/controller.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/controller.cpp b/src/controller.cpp index 59247d94b..837c53e58 100644 --- a/src/controller.cpp +++ b/src/controller.cpp @@ -102,7 +102,9 @@ Controller::Controller(QObject *parent) NotificationsManager::instance().handleNotifications(connection); }); connectSingleShot(connection, &NeoChatConnection::syncDone, this, [this, connection] { - connection->setupPushNotifications(m_endpoint); + if (!m_endpoint.isEmpty()) { + connection->setupPushNotifications(m_endpoint); + } }); } oldAccountCount = m_accountRegistry.size();