From 05e1be86c6cbb896991284087daafdcb758d1075 Mon Sep 17 00:00:00 2001 From: Laurent Peuch Date: Sun, 5 Aug 2018 20:29:10 +0200 Subject: [PATCH] [mod] remove unused variable --- src/yunohost/domain.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/yunohost/domain.py b/src/yunohost/domain.py index 913b7868e..bea496d44 100644 --- a/src/yunohost/domain.py +++ b/src/yunohost/domain.py @@ -242,20 +242,17 @@ def domain_url_available(auth, domain, path): apps_map = app_map(raw=True) # Loop through all apps to check if path is taken by one of them - available = True if domain in apps_map: # Loop through apps for p, a in apps_map[domain].items(): if path == p: - available = False - break + return False # We also don't want conflicts with other apps starting with # same name elif path.startswith(p) or p.startswith(path): - available = False - break + return False - return available + return True def _get_maindomain():