I created a new ActionFilter for the ASP.NET MVC application that I am creating. I have an action that accepts an Http message, and the action method argument takes an object for which I created and registered a custom mediator.
I noticed that inside IActionFilter.OnActionExecuting value of filterContext.Controller.ViewData.Model always null , although it looks like model binding is always called before the OnActionExecuting action OnActionExecuting . In contrast, inside the IActionFilter.OnActionExecuted method of the same action filter, the value of filterContext.Controller.ViewData.Model not null.
Do you guys know if this is by design or a mistake? If the design is their links that describe why this is so? Thanks.
source share