public Question GetNextRankQuestionAfter(Guid currentQuestionId) { var currenQuestion = GetQuestion(currentQuestionId); var currentRank = currenQuestion.Rank; var currentId = currenQuestion.Id; return(QuestionStore .OrderBy(x => x.Rank) .FirstOrDefault(x => x.Rank >= currentRank && x.Id != currentId)); }
public Question GetFirstQuestion() { return(QuestionStore.OrderBy(x => x.Rank).FirstOrDefault()); }