public List <SimilarBoardGame> AddOrGetSimilar(string name) { if (string.IsNullOrWhiteSpace(name)) { return(new List <SimilarBoardGame>()); } var boardGameId = BGGBoardGame.GetBoardGameId(name); if (boardGameId != 0) { var boardGame = BGGBoardGame.GetBoardGameById(boardGameId); if (!CheckIfExists(name)) { Add(boardGame); } return(new List <SimilarBoardGame>()); } var similarBoardGameList = BGGBoardGame.GetSimilarBoardGameList(name).ToList(); return(similarBoardGameList.Take(10).ToList()); }
public BoardGame GetBGGBoardGameById(int id) { return(BGGBoardGame.GetBoardGameById(id)); }