private void GetProblems() { var problems = new List <Problem>(); problems = _problemRepo.GetAll(); foreach (var problem in problems) { var user = _userRepo.GetUserById(problem.AuthorID); Problems.Add(problem, user); } }