I have a controller action that when called from client goes through the JwtMiddleware
Invoke
method. But when I return from the action using BaseController
Ok
method method Invoke
is not called. Is that correct behaviour?
CodePudding user response:
public class SampleActionFilter : IActionFilter
{
public void OnActionExecuting(ActionExecutingContext context)
{
// Do something before the action executes.
}
public void OnActionExecuted(ActionExecutedContext context)
{
// Do something after the action executes.
}
}