From 71a0c077a2b09d137dabe82d4fcf5ce258f52a5a Mon Sep 17 00:00:00 2001 From: Mark Dykun Date: Sat, 20 Jan 2018 21:28:11 -0500 Subject: [PATCH] Update sample2.cs (#5229) The method signature was wrong for GetAllProducts and GetProductById .. Correcting to return the correct results --- .../routing-in-aspnet-web-api/samples/sample2.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/aspnet/web-api/overview/web-api-routing-and-actions/routing-in-aspnet-web-api/samples/sample2.cs b/aspnet/web-api/overview/web-api-routing-and-actions/routing-in-aspnet-web-api/samples/sample2.cs index 2bfa8c5f13..9809fab9e8 100644 --- a/aspnet/web-api/overview/web-api-routing-and-actions/routing-in-aspnet-web-api/samples/sample2.cs +++ b/aspnet/web-api/overview/web-api-routing-and-actions/routing-in-aspnet-web-api/samples/sample2.cs @@ -1,6 +1,6 @@ public class ProductsController : ApiController { - public void GetAllProducts() { } - public IEnumerable GetProductById(int id) { } + public IEnumerable GetAllProducts() { } + public Product GetProductById(int id) { } public HttpResponseMessage DeleteProduct(int id){ } -} \ No newline at end of file +}