How do i modify the following from Autofac to use the Common Service Locator (where _context is of type IComponentContext):
var query = _context.Resolve<IContentQuery>(TypedParameter.From<IContentManager>(this));
The code above is taken from Orchard and and i'm trying to remove the dependency on Autofac. Usually i'd try something like:
var query = ServiceLocator.Current.GetInstance<IContentQuery>();
However this returns null and i can't see how to handle the TypedParameter stuff as i don't understand what it's doing.
I'd really appreciate it if someone could help. Thanks