Update SampleAsyncActionFilter.cs (#4259)

The existing code sample implies that the user can access the result of the action method in `context.Result`, but that is not the case. User needs to capture the result of the `next` delegate in order to access this info.
pull/4298/head
Toby Johnson 2017-09-14 22:36:55 -04:00 committed by Scott Addie
parent f8f6b5934b
commit 669347ee62
1 changed files with 3 additions and 3 deletions

View File

@ -10,8 +10,8 @@ namespace FiltersSample.Filters
ActionExecutionDelegate next)
{
// do something before the action executes
await next();
// do something after the action executes
var resultContext = await next();
// do something after the action executes; resultContext.Result will be set
}
}
}
}