public StatisticsDto GetStatistics(string userId) { var statistics = new StatisticsDto { Boards = _userBoardRepository.GetNumberOfBoards(userId), Lists = _listRepository.GetNumberOfLists(userId), Cards = _cardRepository.GetNumberOfCards(userId), Collaborators = _userBoardRepository.GetNumberOfCollaborators(userId) }; var lastModified = _userBoardRepository.GetThreeLastVisitedBoards(userId); statistics.LatestUserBoards = _mapper.Map <ICollection <UserBoardDto> >(lastModified); foreach (var latestUserBoard in statistics.LatestUserBoards) { latestUserBoard.Board.ObfuscatedId = _obfuscator.Obfuscate(latestUserBoard.BoardId); } return(statistics); }