Reply ApiSummonerProfile(Request request) { PrivilegeCheck(request); var arguments = request.Arguments; string regionAbbreviation = (string)request.Arguments[0]; int accountId = (int)request.Arguments[1]; Worker worker = GetWorkerByAbbreviation(regionAbbreviation); SummonerProfileResult output; Summoner summoner = StatisticsService.GetSummoner(worker.Region, accountId); if (summoner != null) { output = new SummonerProfileResult(summoner); } else { output = new SummonerProfileResult(OperationResult.NotFound); } return(GetJSONReply(output)); }
Reply ApiSummonerProfile(Request request) { PrivilegeCheck(request); var arguments = request.Arguments; string regionAbbreviation = (string)request.Arguments[0]; int accountId = (int)request.Arguments[1]; Worker worker = GetWorkerByAbbreviation(regionAbbreviation); SummonerProfileResult output; Summoner summoner = StatisticsService.GetSummoner(worker.Region, accountId); if (summoner != null) output = new SummonerProfileResult(summoner); else output = new SummonerProfileResult(OperationResult.NotFound); return GetJSONReply(output); }