From ef42aa5d384e4788adba76caf4126b2e9571e333 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joakim=20Hells=C3=A9n?= Date: Mon, 13 Dec 2021 17:30:43 +0100 Subject: [PATCH] Exit when feed already exists --- discord_rss_bot/main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/discord_rss_bot/main.py b/discord_rss_bot/main.py index b026a07..6b175ef 100644 --- a/discord_rss_bot/main.py +++ b/discord_rss_bot/main.py @@ -28,6 +28,7 @@ def add( except FeedExistsError: # If the feed already exists, print a message typer.echo(f"{feed_url} already exists") + raise typer.Exit() # Update the feeds reader.update_feeds()