public async Task <FilteredDataViewModel <CommunityViewModel> > Handle(GetCommunitiesQuery request, CancellationToken cancellationToken) { IEnumerable <CommunityViewModel> communities = await _communityService.GetCommunitiesAsync(request.SearchParams); int communitiesCount = await _communityService.GetCommunitiesCountAsync(request.SearchParams); return(new FilteredDataViewModel <CommunityViewModel> { Data = communities, Count = communitiesCount, }); }