Skip to content

Commit

Permalink
ConfigSettingLayoutRenderer - Improve support for RegisterServiceProv…
Browse files Browse the repository at this point in the history
…ider (#579)
  • Loading branch information
snakefoot committed Mar 22, 2022
1 parent 3dc14e4 commit f2248f2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ protected override void InitializeLayoutRenderer()
try
{
// Avoid NLogDependencyResolveException when possible
if (!ReferenceEquals(ResolveService<IServiceProvider>(), LoggingConfiguration?.LogFactory?.ServiceRepository))
if (!ReferenceEquals(ResolveService<IServiceProvider>(), LoggingConfiguration?.LogFactory?.ServiceRepository ?? NLog.LogManager.LogFactory.ServiceRepository))
{
_serviceConfiguration = ResolveService<IConfiguration>();
}
Expand Down

0 comments on commit f2248f2

Please sign in to comment.