Remove useless ToString (#9811)

This commit is contained in:
Gérald Barré 2019-04-29 11:56:54 -04:00 committed by Chris Ross
parent 17b6baa0bd
commit 2624e73172
3 changed files with 5 additions and 5 deletions

View File

@ -73,7 +73,7 @@ namespace Microsoft.AspNetCore.Antiforgery
if (_options.Cookie.Path != null)
{
options.Path = _options.Cookie.Path.ToString();
options.Path = _options.Cookie.Path;
}
else
{

View File

@ -1,4 +1,4 @@
// Copyright (c) .NET Foundation. All rights reserved.
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System;
@ -34,7 +34,7 @@ namespace Microsoft.AspNetCore.Hosting.Internal
case 3:
return new KeyValuePair<string, object>("ContentLength", _request.ContentLength);
case 4:
return new KeyValuePair<string, object>("Scheme", _request.Scheme.ToString());
return new KeyValuePair<string, object>("Scheme", _request.Scheme);
case 5:
return new KeyValuePair<string, object>("Host", _request.Host.ToString());
case 6:

View File

@ -1,4 +1,4 @@
// Copyright (c) .NET Foundation. All rights reserved.
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System;
@ -43,7 +43,7 @@ namespace Microsoft.AspNetCore.Http.Internal
}
else
{
return Scheme.ToLowerInvariant() + "://" + Host.ToLowerInvariant() + ":" + Port.ToString(CultureInfo.InvariantCulture) + PathBase.ToString(CultureInfo.InvariantCulture);
return Scheme.ToLowerInvariant() + "://" + Host.ToLowerInvariant() + ":" + Port.ToString(CultureInfo.InvariantCulture) + PathBase;
}
}