Skip to content

Commit

Permalink
logging
Browse files Browse the repository at this point in the history
  • Loading branch information
tippmar-nr committed Oct 25, 2023
1 parent 531ea2d commit d53258e
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Http.Features;
using NewRelic.Agent.Api;
using NewRelic.Agent.Extensions.Logging;

namespace NewRelic.Providers.Wrapper.AspNetCore6Plus
{
Expand All @@ -19,6 +20,7 @@ public BrowserInjectionMiddleware(RequestDelegate next, IAgent agent, string run
// Check if the next middleware is of the required type
var fullName = next?.Target?.GetType().FullName;
_runMiddleware = fullName == runBefore;
agent.Logger.Log(Level.Finest, $"BrowserInjectionMiddleware: Next middleware is: {fullName}. Middleware {(_runMiddleware ? "will" : "will not")} run.");

_next = next;
_agent = agent;
Expand Down

0 comments on commit d53258e

Please sign in to comment.