mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-07-23 03:06:01 +02:00
updated validation and removal of whitespace; raise RegistryErrors on create_host and update_host
This commit is contained in:
parent
89a65e597f
commit
91e2a7906b
3 changed files with 4 additions and 6 deletions
|
@ -277,7 +277,7 @@ class Domain(TimeStampedModel, DomainHelper):
|
|||
return response.code
|
||||
except RegistryError as e:
|
||||
logger.error("Error _create_host, code was %s error was %s" % (e.code, e))
|
||||
return e.code
|
||||
raise e
|
||||
|
||||
def _convert_list_to_dict(self, listToConvert: list[tuple[str, list]]):
|
||||
"""converts a list of hosts into a dictionary
|
||||
|
@ -1593,7 +1593,7 @@ class Domain(TimeStampedModel, DomainHelper):
|
|||
return response.code
|
||||
except RegistryError as e:
|
||||
logger.error("Error _update_host, code was %s error was %s" % (e.code, e))
|
||||
return e.code
|
||||
raise e
|
||||
|
||||
def addAndRemoveHostsFromDomain(
|
||||
self, hostsToAdd: list[str], hostsToDelete: list[str]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue