From 9c8d6e63a7473dec0bf80f35fa9e76a89e57ac34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bart=C5=82omiej=20Dach?= Date: Tue, 13 Jan 2026 11:16:10 +0100 Subject: [PATCH] Simplify proxy configuration More clean-up. --- osu.Game/Online/HubClientConnector.cs | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/osu.Game/Online/HubClientConnector.cs b/osu.Game/Online/HubClientConnector.cs index 9dba778e41..c12043c727 100644 --- a/osu.Game/Online/HubClientConnector.cs +++ b/osu.Game/Online/HubClientConnector.cs @@ -2,7 +2,7 @@ // See the LICENCE file in the repository root for full licence text. using System; -using System.Net; +using System.Net.Http; using System.Threading; using System.Threading.Tasks; using Microsoft.AspNetCore.SignalR.Client; @@ -57,13 +57,7 @@ namespace osu.Game.Online { // Configuring proxies is not supported on iOS, see https://github.com/xamarin/xamarin-macios/issues/14632. if (RuntimeInfo.OS != RuntimeInfo.Platform.iOS) - { - // Use HttpClient.DefaultProxy once on net6 everywhere. - // The credential setter can also be removed at this point. - options.Proxy = WebRequest.DefaultWebProxy; - if (options.Proxy != null) - options.Proxy.Credentials = CredentialCache.DefaultCredentials; - } + options.Proxy = HttpClient.DefaultProxy; options.AccessTokenProvider = () => Task.FromResult(API.AccessToken); options.Headers.Add(VERSION_HASH_HEADER, versionHash);