Skip to content
Prev Previous commit
Next Next commit
correcting variable naming
  • Loading branch information
rkargMsft authored and JamesNK committed Aug 15, 2025
commit 50cf8a9be65ba6a50d5758fef1d06c42d92bc438
Original file line number Diff line number Diff line change
Expand Up @@ -390,9 +390,9 @@ private void RecordRequestStartMetrics(HttpContext httpContext)
hasDiagnosticListener = false;

var tagsForCreation = new TagList();
if (_activitySource.HasListeners() && _context.Request.Host.HasValue)
if (_activitySource.HasListeners() && httpContext.Request.Host.HasValue)
{
var (host, port) = _context.Request.Host.HostAndPort;
var (host, port) = httpContext.Request.Host.HostAndPort;
tags.Add("server.address", host);
if (port is not null)
{
Expand Down