private ActionResult Parse4(
     RegisterBitsVerifyModel model,
     BitsParser parser,
     string content,
     Roster roster,
     IEnumerable<Player> players)
 {
     Parse4Result result = parser.Parse4(content, roster.Team);
     var vm = new RegisterBitsResult4
     {
         BitsMatchId = roster.BitsMatchId,
         TeamScore = result.TeamScore,
         OpponentScore = result.OpponentScore,
         RosterId = model.RosterId,
         Serie1 = result.Series.ElementAtOrDefault(0),
         Serie2 = result.Series.ElementAtOrDefault(1),
         Serie3 = result.Series.ElementAtOrDefault(2),
         Serie4 = result.Series.ElementAtOrDefault(3)
     };
     ViewBag.players = players.Select(x => new PlayerViewModel(x))
         .ToArray();
     return View("RegisterBitsVerify4", vm);
 }
        public ActionResult RegisterBitsVerify(RegisterBitsVerifyModel model)
        {
            if (ModelState.IsValid == false)
            {
                ViewBag.rosterid = DocumentSession.CreateRosterSelectList(model.Season);
                return View("RegisterBits", model);
            }

            var roster = DocumentSession.Include<Roster>(r => r.Players)
                .Load<Roster>(model.RosterId);
            if (roster == null)
                throw new HttpException(404, "Roster not found");

            var players = roster.Players
                                .Select(x => DocumentSession.Load<Player>(x))
                                .ToArray();
            var parser = new BitsParser(players);
            var content = bitsClient.DownloadMatchResult(roster.BitsMatchId);
            if (roster.IsFourPlayer)
            {
                var parse4Result = Parse4(model, parser, content, roster, players);
                return parse4Result;
            }

            var parseResult = Parse(model, parser, content, roster, players);
            return parseResult;
        }