From 2fa1d48f0159385b8a98587a8fb3e1974621207f Mon Sep 17 00:00:00 2001 From: dgtlmoon Date: Tue, 25 Jan 2022 10:22:39 +0100 Subject: [PATCH] Don't allow duplicate URLs on import re #377 --- changedetectionio/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changedetectionio/__init__.py b/changedetectionio/__init__.py index bc2d79eb..1bd30e5d 100644 --- a/changedetectionio/__init__.py +++ b/changedetectionio/__init__.py @@ -629,7 +629,7 @@ def changedetection_app(config=None, datastore_o=None): for url in urls: url = url.strip() # Flask wtform validators wont work with basic auth, use validators package - if len(url) and validators.url(url): + if len(url) and validators.url(url) and not datastore.url_exists(url): new_uuid = datastore.add_watch(url=url.strip(), tag="") # Straight into the queue. update_q.put(new_uuid)