/// <summary> /// Returns a Tuple containing a pending rating, as well as the current entry /// of the game that the pending rating is for /// </summary> /// <param name="id">Id of the pending rating to get</param> /// <returns> /// A Tuple - Item1 is the entry as it exists now on the public-facing site, /// Item2 is the requested pending rating as a PendingDisplayModel /// </returns> internal static Tuple <DisplayGame, PendingDisplayModel> GetPendingSubmissionWithCurrentRating(int id) { var pendingRaw = DbAccess.GetPendingSubmission(id); if (pendingRaw == null) { return(null); } var pending = new PendingDisplayModel(pendingRaw); var currentRating = CreateDisplayGameObject(pendingRaw.GameId); return(new Tuple <DisplayGame, PendingDisplayModel>(currentRating, pending)); }