From cc9321b64827d4f04c76c3633b2e850ac45d74cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lukas=20Br=C3=BCbach?= <44814898+BruebachL@users.noreply.github.com> Date: Fri, 6 Nov 2026 09:57:14 +0100 Subject: [PATCH] [DeckSync] Drop ineffective UniqueConnection flags on lambda connects --- .../interface/deck_sync/deck_sync_manager.cpp | 42 ++++++++----------- 1 file changed, 18 insertions(+), 24 deletions(-) diff --git a/cockatrice/src/interface/deck_sync/deck_sync_manager.cpp b/cockatrice/src/interface/deck_sync/deck_sync_manager.cpp index 1bcdbc70f..060ed47ff 100644 --- a/cockatrice/src/interface/deck_sync/deck_sync_manager.cpp +++ b/cockatrice/src/interface/deck_sync/deck_sync_manager.cpp @@ -106,31 +106,25 @@ DeckSyncManager::DeckSyncManager(AbstractClient *_client, ColorIdentityProvider if (client == nullptr) { return; } - connect( - client, &AbstractClient::statusChanged, this, - [this](ClientStatus status) { - if (status == StatusDisconnected) { - offline = true; - debounceTimer->stop(); - // A run cannot survive the session it was started on: the in-flight - // command comes back RespNotConnected, the remaining queue would be - // sent on a dead client, and a re-login as another account would - // receive this profile's uploads and deletes. - if (syncing) { - activeConflict = ActiveConflict(); - failSync(tr("Disconnected.")); - } + connect(client, &AbstractClient::statusChanged, this, [this](ClientStatus status) { + if (status == StatusDisconnected) { + offline = true; + debounceTimer->stop(); + // A run cannot survive the session it was started on: the in-flight + // command comes back RespNotConnected, the remaining queue would be + // sent on a dead client, and a re-login as another account would + // receive this profile's uploads and deletes. + if (syncing) { + activeConflict = ActiveConflict(); + failSync(tr("Disconnected.")); } - }, - Qt::UniqueConnection); - connect( - client, &AbstractClient::userInfoChanged, this, - [this](const ServerInfo_User &userInfo) { - offline = false; - serverUsername = QString::fromStdString(userInfo.name()); - autoSyncSoon(); - }, - Qt::UniqueConnection); + } + }); + connect(client, &AbstractClient::userInfoChanged, this, [this](const ServerInfo_User &userInfo) { + offline = false; + serverUsername = QString::fromStdString(userInfo.name()); + autoSyncSoon(); + }); } void DeckSyncManager::setServerIdentity(const QString &host, int port, const QString &username)