Merge remote-tracking branch 'origin/release/2.2'

This commit is contained in:
James Newton-King 2018-09-27 10:53:30 -07:00
commit 6c1c594b83
No known key found for this signature in database
GPG Key ID: 0A66B2F456BF5526
3 changed files with 5 additions and 3 deletions

View File

@ -11,6 +11,7 @@ namespace Microsoft.AspNetCore.Builder
{
public static class EndpointRoutingApplicationBuilderExtensions
{
// Property key is used by MVC package to check that routing is registered
private const string EndpointRoutingRegisteredKey = "__EndpointRoutingMiddlewareRegistered";
public static IApplicationBuilder UseEndpointRouting(this IApplicationBuilder builder)

View File

@ -80,7 +80,7 @@ namespace Microsoft.AspNetCore.Routing
foreach (var dataSource in _dataSources)
{
Extensions.Primitives.ChangeToken.OnChange(
ChangeToken.OnChange(
dataSource.GetChangeToken,
HandleChange);
}

View File

@ -8,6 +8,7 @@ using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Routing.Internal;
using Microsoft.AspNetCore.Routing.Template;
using Microsoft.AspNetCore.Routing.Tree;
using Microsoft.Extensions.Primitives;
namespace Microsoft.AspNetCore.Routing
{
@ -25,7 +26,7 @@ namespace Microsoft.AspNetCore.Routing
BuildOutboundMatches();
// Register for changes in endpoints
Extensions.Primitives.ChangeToken.OnChange(
ChangeToken.OnChange(
_dataSource.GetChangeToken,
HandleChange);
}
@ -61,7 +62,7 @@ namespace Microsoft.AspNetCore.Routing
// re-register the callback as the change token is one time use only and a new change token
// is produced every time
Extensions.Primitives.ChangeToken.OnChange(
ChangeToken.OnChange(
_dataSource.GetChangeToken,
HandleChange);
}