Exemple #1
0
def _fetch_podcast(url):
    """Fetches the podcast and stores it in the database.

    This should only be called if the podcast is not in the database, or if the podcast
    needs to be updated. other uses should use get_podcast_by_url.
    """
    try:
        podcast = fetcher.fetch(url)
    except InvalidFeed:
        return None
    return podcast.save_to_db()
Exemple #2
0
def update_podcast(podcast):
    """Refetches the podcast corresponding to the given podcast object."""
    fetcher.fetch(podcast.url).save_to_db()