From 80422bfe45d1caa072081b9a3f73fd0b9d059925 Mon Sep 17 00:00:00 2001 From: Rick Anderson Date: Thu, 22 Jun 2017 14:12:24 -0700 Subject: [PATCH] Update search3.md (#3554) --- aspnetcore/includes/mvc-intro/search3.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aspnetcore/includes/mvc-intro/search3.md b/aspnetcore/includes/mvc-intro/search3.md index 5c9c847f0a..e0afdf13e1 100644 --- a/aspnetcore/includes/mvc-intro/search3.md +++ b/aspnetcore/includes/mvc-intro/search3.md @@ -59,6 +59,6 @@ Examine the lambda expression used in the following HTML Helper: `@Html.DisplayNameFor(model => model.movies[0].Title)` -In the preceding code, the `DisplayNameFor` HTML Helper inspects the `Title` property referenced in the lambda expression to determine the display name. Since the lambda expression is inspected rather than evaluated, you don't receive an access violation when `model`, `model.movies`, or `model.movies[0]` are `null` or empty. When the lambda expression is evaluated (for example, `@Html.DisplayFor(model => model.movies[0].Title)`), the model's property values are evaluated. +In the preceding code, the `DisplayNameFor` HTML Helper inspects the `Title` property referenced in the lambda expression to determine the display name. Since the lambda expression is inspected rather than evaluated, you don't receive an access violation when `model`, `model.movies`, or `model.movies[0]` are `null` or empty. When the lambda expression is evaluated (for example, `@Html.DisplayFor(modelItem => item.Title)`), the model's property values are evaluated. Test the app by searching by genre, by movie title, and by both.