Use application proxy when setting global proxy setting via network settings

Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
Claudio Cambra 2024-07-22 15:58:26 +08:00
parent 564be17ce4
commit eeb9cc284a
No known key found for this signature in database
GPG key ID: C839200C384636B0

View file

@ -227,7 +227,7 @@ void NetworkSettings::saveProxySettings()
_account->setProxyPassword(password);
if (useGlobalProxy) {
_account->networkAccessManager()->setProxy(QNetworkProxy(QNetworkProxy::DefaultProxy));
_account->networkAccessManager()->setProxy(QNetworkProxy::applicationProxy());
} else {
const auto proxy = QNetworkProxy(proxyType, host, port, user, password);
_account->networkAccessManager()->setProxy(proxy);