Created an ContentStoreResolver so we can specify a custom ContentStore which means we can return a custom
IDocument. This now means we've opened up the possibility of an abstracted routing lookup system to map to a Document stored anywhere. By default this is obviously Xml but could theoretically be anything, still internal until more review of the API is done.
This commit is contained in:
@@ -58,16 +58,14 @@ namespace Umbraco.Web
|
||||
RoutesCacheResolver.Current.RoutesCache);
|
||||
UmbracoContext.Current = umbracoContext;
|
||||
|
||||
//create a content store
|
||||
var contentStore = new ContentStore(umbracoContext);
|
||||
//create the nice urls
|
||||
var niceUrls = new NiceUrlProvider(contentStore, umbracoContext);
|
||||
var niceUrls = new NiceUrlProvider(ContentStoreResolver.Current.ContentStore, umbracoContext);
|
||||
//create the RoutingContext
|
||||
var routingContext = new RoutingContext(
|
||||
umbracoContext,
|
||||
DocumentLookupsResolver.Current.DocumentLookups,
|
||||
LastChanceLookupResolver.Current.LastChanceLookup,
|
||||
contentStore,
|
||||
ContentStoreResolver.Current.ContentStore,
|
||||
niceUrls);
|
||||
//assign the routing context back to the umbraco context
|
||||
umbracoContext.RoutingContext = routingContext;
|
||||
|
||||
Reference in New Issue
Block a user