LeagueWrap\Dto\ChampionMasteryList::getChampion PHP Method

getChampion() public method

Get a champion by its id.
public getChampion ( integer $championId ) : ChampionMastery | null
$championId integer
return ChampionMastery | null
    public function getChampion($championId)
    {
        foreach ($this->info as $mastery) {
            if ($mastery->championId == $championId) {
                return $mastery;
            }
        }
        return null;
    }
ChampionMasteryList