diff --git a/SystemExtensions.NetStandard/Logging/ScopedLogger.cs b/SystemExtensions.NetStandard/Logging/ScopedLogger.cs index 2089771..0879c81 100644 --- a/SystemExtensions.NetStandard/Logging/ScopedLogger.cs +++ b/SystemExtensions.NetStandard/Logging/ScopedLogger.cs @@ -71,7 +71,7 @@ namespace System.Logging public static ScopedLogger Create(ILogger logger, string scope, string flowId) { - return new ScopedLogger(logger, scope.ThrowIfNull(nameof(scope)), flowId.ThrowIfNull(nameof(flowId))); + return new ScopedLogger(logger, scope.ThrowIfNull(nameof(scope)), flowId); } } } \ No newline at end of file diff --git a/SystemExtensions.NetStandard/SystemExtensions.NetStandard.csproj b/SystemExtensions.NetStandard/SystemExtensions.NetStandard.csproj index 8bf7eec..3b419a0 100644 --- a/SystemExtensions.NetStandard/SystemExtensions.NetStandard.csproj +++ b/SystemExtensions.NetStandard/SystemExtensions.NetStandard.csproj @@ -7,7 +7,7 @@ LICENSE true System - 1.4 + 1.4.1 Alexandru Macocian https://github.com/AlexMacocian/SystemExtensions Extensions for the System namespace diff --git a/SystemExtensions.Tests/Logging/ScopedLoggerTests.cs b/SystemExtensions.Tests/Logging/ScopedLoggerTests.cs index 2889486..5eb6d1f 100644 --- a/SystemExtensions.Tests/Logging/ScopedLoggerTests.cs +++ b/SystemExtensions.Tests/Logging/ScopedLoggerTests.cs @@ -33,15 +33,9 @@ namespace System.Logging.Tests } [TestMethod] - public void CreateLogger_NullFlow_ThrowsArgumentNullException() + public void CreateLogger_NullFlow_ReturnsScopedLogger() { - var action = new Action(() => - { - var scopedLogger = this.cachingLogger.CreateScopedLogger(nameof(this.CreateLogger_NullFlow_ThrowsArgumentNullException), null); - }); - - - action.Should().Throw(); + var scopedLogger = this.cachingLogger.CreateScopedLogger(nameof(this.CreateLogger_NullFlow_ReturnsScopedLogger), null); } [TestMethod]