Skip to content

Commit 51f6e2f

Browse files
committed
added theninclude
1 parent 1ca7df2 commit 51f6e2f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

exercise.wwwapi/Endpoints/PostEndpoints.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ private static async Task<IResult> GetAllPosts(IRepository<Post> postRepository,
8989
ClaimsPrincipal user)
9090
{
9191
var results = await postRepository.GetWithIncludes(q => q.Include(p => p.Author)
92-
.Include(c => c.Comments)
92+
.Include(c => c.Comments).ThenInclude(u => u.User)
9393
.Include(l => l.Likes));
9494

9595
var postData = new PostsSuccessDTOVol2

0 commit comments

Comments
 (0)