mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-04-24 19:08:18 +08:00
Explicitly injecting the Controller's ActionInvoker since upgrading to MVC3P1 somehow broke the InjectActionInvoker extension method
--HG-- branch : mvc3p1
This commit is contained in:
parent
69c901e5c0
commit
610d79fde6
@ -93,7 +93,11 @@ namespace Orchard.Environment.ShellBuilders {
|
||||
.EnableDynamicProxy(dynamicProxyContext)
|
||||
.Keyed<IController>(serviceKey)
|
||||
.InstancePerDependency()
|
||||
.InjectActionInvoker();
|
||||
.OnActivating(e => {
|
||||
var controller = e.Instance as Controller;
|
||||
if (controller != null)
|
||||
controller.ActionInvoker = (IActionInvoker)e.Context.Resolve(new TypedService(typeof(IActionInvoker)));
|
||||
});
|
||||
}
|
||||
|
||||
// Register code-only registrations specific to a shell
|
||||
|
Loading…
Reference in New Issue
Block a user