From d4142166381da4e9fb924a83fd54848de09cb497 Mon Sep 17 00:00:00 2001 From: adospace Date: Wed, 28 Aug 2024 11:30:10 +0200 Subject: [PATCH] Fix described in #21132 --- src/Foundation/NSUrlSessionHandler.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Foundation/NSUrlSessionHandler.cs b/src/Foundation/NSUrlSessionHandler.cs index 638211139a35..a2029e14a34d 100644 --- a/src/Foundation/NSUrlSessionHandler.cs +++ b/src/Foundation/NSUrlSessionHandler.cs @@ -651,7 +651,10 @@ public bool PreAuthenticate { [EditorBrowsable (EditorBrowsableState.Never)] public IWebProxy? Proxy { get => null; - set => throw new PlatformNotSupportedException (); + set { + if (value is not null) + throw new PlatformNotSupportedException (); + } } // There doesn't seem to be a trivial way to specify the protocols to accept (or not)