diff options
author | André Glüpker <git@wgmd.de> | 2024-05-01 10:23:46 +0200 |
---|---|---|
committer | André Glüpker <git@wgmd.de> | 2024-05-01 10:23:46 +0200 |
commit | 15a2cd3c1a84ab94cbf8df30dcb7ed30502883fc (patch) | |
tree | 86a9fc7220eef4353148d9aa687e7bdade3f0540 /zdf.py | |
parent | 02d7f97cc63177ae875caa2b28a03c03582c4224 (diff) | |
download | rss-feeds-15a2cd3c1a84ab94cbf8df30dcb7ed30502883fc.tar.gz rss-feeds-15a2cd3c1a84ab94cbf8df30dcb7ed30502883fc.tar.bz2 rss-feeds-15a2cd3c1a84ab94cbf8df30dcb7ed30502883fc.zip |
Improve naming
Diffstat (limited to 'zdf.py')
-rwxr-xr-x | zdf.py | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -15,18 +15,18 @@ def getText(dom, element): return "" -def zdf(feed): - url = f"https://www.zdf.de/rss/zdf/{feed}" +def zdf(show_url): + url = f"https://www.zdf.de/rss/zdf/{show_url}" try: - res = urlopen(Request(url)) + response = urlopen(Request(url)) except Exception as exc: logging.error("Request to zdf failed.", exc_info=exc) return None try: - rss = res.read() - xml = parseString(rss) + rss_raw = response.read() + xml = parseString(rss_raw) except Exception as exc: logging.error("Parsing to zdf failed.", exc_info=exc) return None |