<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def team_media(self, team, year=None, tag=None):
 """ Get media for a given team. :param team: Team to get media of. :param year: Year to get media from. :param tag: Get only media with a given tag. :return: List of Media objects. """

        return [Media(raw) for raw in self._get('team/%s/media%s%s' % (self.team_key(team), ('/tag/%s' % tag) if tag else '', ('/%s' % year) if year else ''))]