Skip to content

Commit 357e429

Browse files
committed
Do not pass proxy settings if ProxyServer is false
1 parent 72df07c commit 357e429

2 files changed

Lines changed: 12 additions & 5 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2121

2222
- Cache control is no longer used. A cache path will always be used now. To use a incognito/private mode, where no profile-specific data is persisted to disk, set incognito mode to true.
2323

24+
### Fixed
25+
26+
- Do not pass proxy settings if ProxyServer is false
27+
2428
## [2.2.0] - 2024-09-20
2529

2630
### Added

src/Packages/UnityWebBrowser/Runtime/Core/WebBrowserClient.cs

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -376,12 +376,15 @@ internal void Init()
376376
}
377377

378378
//Setup proxy
379-
argsBuilder.AppendArgument("proxy-server", proxySettings.ProxyServer);
380-
if (!string.IsNullOrWhiteSpace(proxySettings.Username))
381-
argsBuilder.AppendArgument("proxy-username", proxySettings.Username, true);
379+
if (proxySettings.ProxyServer)
380+
{
381+
argsBuilder.AppendArgument("proxy-server", true);
382+
if (!string.IsNullOrWhiteSpace(proxySettings.Username))
383+
argsBuilder.AppendArgument("proxy-username", proxySettings.Username, true);
382384

383-
if (!string.IsNullOrWhiteSpace(proxySettings.Password))
384-
argsBuilder.AppendArgument("proxy-password", proxySettings.Password, true);
385+
if (!string.IsNullOrWhiteSpace(proxySettings.Password))
386+
argsBuilder.AppendArgument("proxy-password", proxySettings.Password, true);
387+
}
385388

386389
//Make sure not to include this, its for testing
387390
#if UWB_ENGINE_PRJ //Define for backup, cause I am dumb as fuck and gonna accidentally include this in a release build one day

0 commit comments

Comments
 (0)