Skip to content
Permalink
Browse files

fix: remove exception in .netstandard 2.0 code, due to increased numb…

…er of .net standard projects (#2163)
  • Loading branch information...
glennawatson committed Sep 9, 2019
1 parent 5d5c66e commit a342f88b602f9165a4b491b04f19e9f02d1bbfa5
Showing with 8 additions and 1 deletion.
  1. +8 −1 src/ReactiveUI/Platforms/netstandard2.0/PlatformRegistrations.cs
@@ -4,6 +4,7 @@
// See the LICENSE file in the project root for full license information.

using System;
using System.Reactive.Concurrency;

namespace ReactiveUI
{
@@ -16,7 +17,13 @@ public class PlatformRegistrations : IWantsToRegisterStuff
/// <inheritdoc/>
public void Register(Action<Func<object>, Type> registerFunction)
{
throw new Exception("You are referencing the Portable version of ReactiveUI in an App. Please change your reference to the specific version for your platform found here: https://reactiveui.net/docs/getting-started/installation");
if (registerFunction == null)
{
throw new ArgumentNullException(nameof(registerFunction));
}

RxApp.TaskpoolScheduler = TaskPoolScheduler.Default;
RxApp.MainThreadScheduler = DefaultScheduler.Instance;
}
}
}

0 comments on commit a342f88

Please sign in to comment.
You can’t perform that action at this time.