From 7e90db5b304347635cfaef61cb6c72ed17e2bdfc Mon Sep 17 00:00:00 2001 From: Bjarke Berg Date: Mon, 6 Jul 2020 13:01:25 +0200 Subject: [PATCH] Cleanup based on review Signed-off-by: Bjarke Berg --- src/Umbraco.Core/Composing/Current.cs | 2 +- .../TestServerTest/UmbracoTestServerTestBase.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Umbraco.Core/Composing/Current.cs b/src/Umbraco.Core/Composing/Current.cs index 41e1ea2c21..055a29228a 100644 --- a/src/Umbraco.Core/Composing/Current.cs +++ b/src/Umbraco.Core/Composing/Current.cs @@ -24,7 +24,7 @@ namespace Umbraco.Composing public static IBackOfficeInfo BackOfficeInfo => EnsureInitialized(_backOfficeInfo); public static IProfiler Profiler => EnsureInitialized(_profiler); - public static bool IsInitialized { get; private set; } + public static bool IsInitialized { get; internal set; } [MethodImpl(MethodImplOptions.AggressiveInlining)] private static T EnsureInitialized(T returnValue) diff --git a/src/Umbraco.Tests.Integration/TestServerTest/UmbracoTestServerTestBase.cs b/src/Umbraco.Tests.Integration/TestServerTest/UmbracoTestServerTestBase.cs index d5c2616c6c..66635c12ce 100644 --- a/src/Umbraco.Tests.Integration/TestServerTest/UmbracoTestServerTestBase.cs +++ b/src/Umbraco.Tests.Integration/TestServerTest/UmbracoTestServerTestBase.cs @@ -78,7 +78,7 @@ namespace Umbraco.Tests.Integration.TestServerTest if (Current.IsInitialized) { - typeof(Current).GetProperty(nameof(Current.IsInitialized), BindingFlags.Public | BindingFlags.Static).SetValue(null, false); + Current.IsInitialized = false; } }