mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-08-01 23:42:17 +02:00
fix deletion regex
This commit is contained in:
parent
dea13ec27b
commit
d4a5e3e400
1 changed files with 1 additions and 1 deletions
|
@ -1040,7 +1040,7 @@ class Domain(TimeStampedModel, DomainHelper):
|
|||
|
||||
logger.info("Deleting subdomains for %s", self.name)
|
||||
# check if any subdomains are in use by another domain
|
||||
hosts = Host.objects.filter(name__regex=r".+{}".format(self.name))
|
||||
hosts = Host.objects.filter(name__regex=r".+\.{}".format(self.name))
|
||||
for host in hosts:
|
||||
if host.domain != self:
|
||||
logger.error("Unable to delete host: %s is in use by another domain: %s", host.name, host.domain)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue