From 26613198aa59930b9bb8c41ffe2c8b3f74f4ae94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Lebleu?= Date: Mon, 16 Jun 2014 20:59:43 +0200 Subject: [PATCH] [fix] Attempt to remove domain silently on creation error --- domain.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/domain.py b/domain.py index bf57dcb27..1b7bcf7df 100644 --- a/domain.py +++ b/domain.py @@ -237,8 +237,9 @@ def domain_add(auth, domain, main=False, dyndns=False): os.system('yunohost app ssowatconf > /dev/null 2>&1') except: - # Force domain removal - domain_remove(auth, domain, True) + # Force domain removal silently + try: domain_remove(auth, domain, True) + except: pass raise msignals.display(m18n.n('domain_created'), 'success')