From afc56ad2f73b39fa72bfbdb78b2f20c21604d47c Mon Sep 17 00:00:00 2001 From: Claudio Cambra Date: Thu, 28 Nov 2024 17:58:41 +0800 Subject: [PATCH] Replace QWebSocket::error with errorOccurred Signed-off-by: Claudio Cambra --- src/libsync/pushnotifications.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libsync/pushnotifications.cpp b/src/libsync/pushnotifications.cpp index 89ca8221b75a8..6bfad9d62a535 100644 --- a/src/libsync/pushnotifications.cpp +++ b/src/libsync/pushnotifications.cpp @@ -30,7 +30,7 @@ PushNotifications::PushNotifications(Account *account, QObject *parent) , _account(account) , _webSocket(new QWebSocket(QString(), QWebSocketProtocol::VersionLatest, this)) { - connect(_webSocket, QOverload::of(&QWebSocket::error), this, &PushNotifications::onWebSocketError); + connect(_webSocket, QOverload::of(&QWebSocket::errorOccurred), this, &PushNotifications::onWebSocketError); connect(_webSocket, &QWebSocket::sslErrors, this, &PushNotifications::onWebSocketSslErrors); connect(_webSocket, &QWebSocket::connected, this, &PushNotifications::onWebSocketConnected); connect(_webSocket, &QWebSocket::disconnected, this, &PushNotifications::onWebSocketDisconnected); @@ -76,7 +76,7 @@ void PushNotifications::closeWebSocket() _reconnectTimer->stop(); } - disconnect(_webSocket, QOverload::of(&QWebSocket::error), this, &PushNotifications::onWebSocketError); + disconnect(_webSocket, QOverload::of(&QWebSocket::errorOccurred), this, &PushNotifications::onWebSocketError); disconnect(_webSocket, &QWebSocket::sslErrors, this, &PushNotifications::onWebSocketSslErrors); _webSocket->close(); @@ -174,7 +174,7 @@ void PushNotifications::openWebSocket() const auto webSocketUrl = capabilities.pushNotificationsWebSocketUrl(); qCInfo(lcPushNotifications) << "Open connection to websocket on" << webSocketUrl << "for account" << _account->url(); - connect(_webSocket, QOverload::of(&QWebSocket::error), this, &PushNotifications::onWebSocketError); + connect(_webSocket, QOverload::of(&QWebSocket::errorOccurred), this, &PushNotifications::onWebSocketError); connect(_webSocket, &QWebSocket::sslErrors, this, &PushNotifications::onWebSocketSslErrors); _webSocket->open(webSocketUrl); }