changing to use list instead of stack

This commit is contained in:
Ryan Nowak 2014-06-06 10:49:10 -07:00
parent 69034b78b8
commit a3314a4805
4 changed files with 4 additions and 4 deletions

View File

@ -21,7 +21,7 @@ namespace Microsoft.AspNet.Mvc
public UrlHelper(IContextAccessor<ActionContext> contextAccessor, IActionSelector actionSelector)
{
_httpContext = contextAccessor.Value.HttpContext;
_router = contextAccessor.Value.RouteData.Routers.Peek();
_router = contextAccessor.Value.RouteData.Routers[0];
_ambientValues = contextAccessor.Value.RouteData.Values;
_actionSelector = actionSelector;
}

View File

@ -73,7 +73,7 @@ namespace Microsoft.AspNet.Mvc.Core.Test
{
Values = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase),
};
routeData.Routers.Push(new Mock<IRouter>().Object);
routeData.Routers.Add(new Mock<IRouter>().Object);
return new ActionContext(httpContext,
routeData,

View File

@ -293,7 +293,7 @@ namespace Microsoft.AspNet.Mvc.Core.Test
Values = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase),
};
routeData.Routers.Push(new Mock<IRouter>(MockBehavior.Strict).Object);
routeData.Routers.Add(new Mock<IRouter>(MockBehavior.Strict).Object);
var httpContext = new Mock<HttpContext>(MockBehavior.Strict);

View File

@ -468,7 +468,7 @@ namespace Microsoft.AspNet.Mvc.Core.Test
{
var routeData = new RouteData();
routeData.Values = new Dictionary<string, object>(StringComparer.OrdinalIgnoreCase);
routeData.Routers.Push(router);
routeData.Routers.Add(router);
var actionContext = new ActionContext(context,
routeData,