Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove some ToString allocs #1668

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 1 addition & 1 deletion src/IdentityServer/Services/Default/DefaultEventService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ protected virtual async Task PrepareEventAsync(Event evt)

if (Context.HttpContext?.Connection.LocalIpAddress != null)
{
evt.LocalIpAddress = Context.HttpContext.Connection.LocalIpAddress.ToString() + ":" + Context.HttpContext.Connection.LocalPort;
evt.LocalIpAddress = Context.HttpContext.Connection.LocalIpAddress + ":" + Context.HttpContext.Connection.LocalPort;
}
else
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ public async Task consent_response_should_reject_modified_request_params()
response.StatusCode.Should().Be(HttpStatusCode.Redirect);
response.Headers.Location.ToString().Should().StartWith("/connect/authorize/callback");

var modifiedAuthorizeCallback = "https://server" + response.Headers.Location.ToString();
var modifiedAuthorizeCallback = "https://server" + response.Headers.Location;
modifiedAuthorizeCallback = modifiedAuthorizeCallback.Replace("api2", "api1%20api2");

response = await _mockPipeline.BrowserClient.GetAsync(modifiedAuthorizeCallback);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ public async Task multiple_prompt_values_should_be_accepted()
parameters.Add(OidcConstants.AuthorizeRequest.RedirectUri, "https://server/cb");
parameters.Add(OidcConstants.AuthorizeRequest.ResponseType, OidcConstants.ResponseTypes.Code);
parameters.Add(OidcConstants.AuthorizeRequest.ResponseMode, OidcConstants.ResponseModes.Fragment);
parameters.Add(OidcConstants.AuthorizeRequest.Prompt, OidcConstants.PromptModes.Consent.ToString() + " " + OidcConstants.PromptModes.Login.ToString());
parameters.Add(OidcConstants.AuthorizeRequest.Prompt, OidcConstants.PromptModes.Consent + " " + OidcConstants.PromptModes.Login);

var validator = Factory.CreateAuthorizeRequestValidator();
var result = await validator.ValidateAsync(parameters);
Expand Down
Loading