diff --git a/Dotnet/AssetBundleCacher.cs b/Dotnet/AssetBundleCacher.cs index 2c6941e81..f6646594c 100644 --- a/Dotnet/AssetBundleCacher.cs +++ b/Dotnet/AssetBundleCacher.cs @@ -110,9 +110,9 @@ public void DownloadFile(string fileUrl, string hashUrl, int size) #pragma warning disable SYSLIB0014 // Type or member is obsolete client = new WebClient(); #pragma warning restore SYSLIB0014 // Type or member is obsolete + client.Headers.Add("user-agent", Program.Version); if (WebApi.ProxySet) client.Proxy = WebApi.Proxy; - client.Headers.Add("user-agent", Program.Version); DownloadProgress = 0; DownloadSize = size; DownloadCanceled = false; diff --git a/Dotnet/Update.cs b/Dotnet/Update.cs index 6d170d82c..0eba13556 100644 --- a/Dotnet/Update.cs +++ b/Dotnet/Update.cs @@ -81,19 +81,15 @@ public static void DownloadInstallRedist() private static string DownloadFile(string fileUrl) { - HttpClientHandler handler = new HttpClientHandler(); - - if(WebApi.ProxySet) - { - handler.Proxy = WebApi.Proxy; - handler.UseProxy = true; - } - - HttpClient client = new HttpClient(handler); + var httpClientHandler = new HttpClientHandler(); + if (WebApi.ProxySet) + httpClientHandler.Proxy = WebApi.Proxy; + + var httpClient = new HttpClient(httpClientHandler); try { - HttpResponseMessage response = client.GetAsync(fileUrl).Result; + HttpResponseMessage response = httpClient.GetAsync(fileUrl).Result; if (response.IsSuccessStatusCode) { @@ -122,7 +118,7 @@ private static string DownloadFile(string fileUrl) } finally { - client.Dispose(); + httpClient.Dispose(); } } diff --git a/html/src/app.js b/html/src/app.js index 583ffd9ee..02a5b160f 100644 --- a/html/src/app.js +++ b/html/src/app.js @@ -5237,7 +5237,9 @@ speechSynthesis.getVoices(); case 'instance-queue-left': console.log('instance-queue-left', content); - $app.instanceQueueClear(); + var instanceId = content.instanceLocation; + $app.removeQueuedInstance(instanceId); + // $app.instanceQueueClear(); break; case 'content-refresh': @@ -13762,10 +13764,11 @@ speechSynthesis.getVoices(); this.lastLocation$ = L; } var hidePrivate = false; - // (L.accessType === 'group' && !L.groupAccessType) || L.groupAccessType === 'member') if ( this.discordHideInvite && - (L.accessType === 'invite' || L.accessType === 'invite+') + (L.accessType === 'invite' || + L.accessType === 'invite+' || + L.groupAccessType === 'members') ) { hidePrivate = true; }