From 49639301d7b5426928d435aff0f8ebd8167ab127 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Halil=20=C4=B0brahim=20Kalkan?= Date: Fri, 22 Jan 2021 14:43:18 +0300 Subject: [PATCH] Update Part-10.md --- docs/en/Tutorials/Part-10.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/en/Tutorials/Part-10.md b/docs/en/Tutorials/Part-10.md index 84cce260c8..ec68dfe955 100644 --- a/docs/en/Tutorials/Part-10.md +++ b/docs/en/Tutorials/Part-10.md @@ -387,6 +387,12 @@ namespace Acme.BookStore.Books public override async Task> GetListAsync(PagedAndSortedResultRequestDto input) { + //Set a default sorting, if not provided + if (input.Sorting.IsNullOrWhiteSpace()) + { + input.Sorting = nameof(Book.Name); + } + //Get the IQueryable from the repository var queryable = await Repository.GetQueryableAsync(); @@ -489,8 +495,6 @@ namespace Acme.BookStore.Books public async override Task GetAsync(Guid id) { - await CheckGetPolicyAsync(); - var book = await Repository.GetAsync(id); var bookDto = ObjectMapper.Map(book); @@ -503,8 +507,6 @@ namespace Acme.BookStore.Books public async override Task> GetListAsync(PagedAndSortedResultRequestDto input) { - await CheckGetListPolicyAsync(); - //Set a default sorting, if not provided if (input.Sorting.IsNullOrWhiteSpace()) {