diff --git a/src/MusicStore.Spa/Infrastructure/BaseController.cs b/src/MusicStore.Spa/Infrastructure/BaseController.cs index 525cba2033..f9f08ccead 100644 --- a/src/MusicStore.Spa/Infrastructure/BaseController.cs +++ b/src/MusicStore.Spa/Infrastructure/BaseController.cs @@ -40,12 +40,8 @@ namespace Microsoft.AspNet.Mvc { LazyInitializer.EnsureInitialized(ref _modelBinder, ref _modelBinderInitialized, ref _modelBinderInitLocker, () => { - var routeContext = new RouteContext(Context) - { - RouteData = ActionContext.RouteData, - }; - - _compositeValueProvider = new CompositeValueProvider(_valueProviderFactories.Select(vpf => vpf.GetValueProvider(routeContext))); + var factoryContext = new ValueProviderFactoryContext(Context, ActionContext.RouteData.Values); + _compositeValueProvider = new CompositeValueProvider(_valueProviderFactories.Select(vpf => vpf.GetValueProvider(factoryContext))); return new CompositeModelBinder(_modelBinders); });