Skip to content

Commit

Permalink
Minor changes
Browse files Browse the repository at this point in the history
  • Loading branch information
support committed Nov 27, 2023
1 parent 2907be2 commit ae7c53e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public async Task InvokeAsync(HttpContext context)
requestTelemetry.Properties.TryAdd("Store", workContext?.CurrentStore?.Name);
requestTelemetry.Properties.TryAdd("Currency", workContext?.WorkingCurrency?.Name);
requestTelemetry.Properties.TryAdd("Language", workContext?.WorkingLanguage?.Name);

await _next(context);
}
}
9 changes: 6 additions & 3 deletions src/Web/Grand.Web/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,12 @@

var builder = WebApplication.CreateBuilder(args);

//create logger
Log.Logger = new LoggerConfiguration()
.CreateBootstrapLogger();

Log.Information("Starting web application");

builder.Host.UseDefaultServiceProvider((_, options) =>
{
options.ValidateScopes = false;
Expand Down Expand Up @@ -40,9 +46,6 @@
});

//create logger
Log.Logger = new LoggerConfiguration().ReadFrom.Configuration(builder.Configuration).CreateLogger();

//add services
StartupBase.ConfigureServices(builder.Services, builder.Configuration);

Expand Down

0 comments on commit ae7c53e

Please sign in to comment.