diff --git a/lib/yunohost/domain.py b/lib/yunohost/domain.py index 9d3d3f743..ee53bb39e 100644 --- a/lib/yunohost/domain.py +++ b/lib/yunohost/domain.py @@ -159,13 +159,13 @@ def domain_add(auth, domain, dyndns=False): if not auth.add('virtualdomain=%s,ou=domains' % domain, attr_dict): raise MoulinetteError(errno.EIO, m18n.n('domain_creation_failed')) - try: - with open('/etc/yunohost/installed', 'r') as f: - service_regenconf(service='nginx') - service_regenconf(service='metronome') - service_regenconf(service='dnsmasq') - os.system('yunohost app ssowatconf > /dev/null 2>&1') - except IOError: pass + try: + with open('/etc/yunohost/installed', 'r') as f: + service_regenconf(service='nginx') + service_regenconf(service='metronome') + service_regenconf(service='dnsmasq') + os.system('yunohost app ssowatconf > /dev/null 2>&1') + except IOError: pass except: # Force domain removal silently try: domain_remove(auth, domain, True)