serilog / serilog-aspnetcore

Serilog integration for ASP.NET Core
Apache License 2.0
1.29k stars 203 forks source link

Small typo with properties example in documentation #363

Closed ghost closed 4 months ago

ghost commented 4 months ago

Believe there is a bug in the example in https://github.com/serilog/serilog-aspnetcore#pushing-properties-to-the-iloggert. It should be LogContext.PushProperty rather than logger.PushProperty. Alternatively or additionally it can also point to https://github.com/serilog/serilog/wiki/Enrichment#the-logcontext for more information.

However it would be be a nice to have ILogger.PushProperty which then forwards to LogContext.PushProperty.

ghost commented 4 months ago

PR #364