Asynchronous action methods not working
apircher opened this issue · 1 comments
NinjectControllerFactory.CreateActionInvoker creates a ControllerActionInvoker-Subclass (Ninject.Web.Mvc.NinjectActionInvoker). But for asynchronous action methods to work correctly an AsyncControllerActionInvoker-Subclass is needed.
I have a solution that works for me - but it feels "not DRY". I created an AsyncNinjectActionInvoker that inherits from AsyncControllerActionInvoker - with the same GetFilters-Method as the NinjectActionInvoker.
Presumably it would be better to make NinjectActionInvoker inherit from AsyncControllerActionInvoker - but I was not sure whether that brings some overhead to all synchronous action methods.
UPDATE: Meanwhile I decided to undo my last changes and just change the NinjectActionInvoker to inherit from AsyncControllerActionInvoker.
Added support in 2.1.0.24