Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/NATS.Client.Core/NatsConnection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,8 @@ private async Task ConnectSocketAsync(NatsUri uri)
target = await OnConnectingAsync(target).ConfigureAwait(false);
if (target.Host != uri.Host || target.Port != uri.Port)
{
uri = uri with { Uri = new UriBuilder(uri.Uri) { Host = target.Host, Port = target.Port, }.Uri };
var modifiedUri = new UriBuilder(uri.Uri) { Host = target.Host, Port = target.Port }.Uri;
uri = new NatsUri(modifiedUri.ToString(), uri.IsSeed, uri.Uri.Scheme);
}
}
Comment on lines 476 to 488
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe this can be extracted into a method?


Expand Down