Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
@ghost_load_on
def name(self) -> str:
return self._data[ItemData].name
@ghost_load_on
@lazy
def image(self) -> Image:
"""The image information for this item."""
image = Image.from_data(self._data[ItemData].image)
image(version=self.version)
return image
@ghost_load_on
def description(self) -> str:
return self._data[ItemData].description
@ghost_load_on
def cdn(self) -> str:
return self._data[RealmData].cdn
@ghost_load_on
@lazy
def spells(self) -> List[ChampionSpell]:
"""This champion's spells."""
keys = {0: "Q", 1: "W", 2: "E", 3: "R"}
spells = []
for i, spell in enumerate(self._data[ChampionData].spells):
spell.keyboard_key = keys[i]
spells.append(ChampionSpell.from_data(spell))
return SearchableList(spells)
@ghost_load_on
def id(self) -> str:
return self._data[GrandmasterLeagueListData].id
@ghost_load_on
@lazy
def image(self) -> PILImage:
return configuration.settings.pipeline.get(PILImage, query={"url": self.url})
@ghost_load_on
def max_stacks(self) -> int:
return self._data[ItemData].max_stacks
@ghost_load_on
def tier(self) -> int:
return self._data[ItemData].tier
@ghost_load_on
@lazy
def platform(self) -> Platform:
return self.region.platform