public static ContentViewModel WithChildren(this ContentViewModel i) { var children = ContentApi.SelectByParent(i.Id); i.ChildrenCount = ContentApi.GetChildrenCount(i.Id); i.Children = children.Select(c => ContentViewModel.New(c).WithUser().WithTags()).ToList(); return(i); }