[RSS] Catch feeds that have no content

This commit is contained in:
aikaterna
2020-10-05 08:43:06 -07:00
committed by GitHub
parent 5bfbc3b83b
commit b431b599ae

View File

@@ -879,6 +879,9 @@ class RSS(commands.Cog):
to_fill = QuietTemplate(template) to_fill = QuietTemplate(template)
message = to_fill.quiet_safe_substitute(name=bold(name), **feedparser_plus_obj) message = to_fill.quiet_safe_substitute(name=bold(name), **feedparser_plus_obj)
if len(message.strip(" ")) == 0:
message = None
if not message: if not message:
log.debug(f"{name} feed in {channel.name} ({channel.id}) has no valid tags, not posting anything.") log.debug(f"{name} feed in {channel.name} ({channel.id}) has no valid tags, not posting anything.")
return return