mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-05-15 17:17:02 +02:00
Let email field be null
This commit is contained in:
parent
545a5d80a6
commit
8da6578b46
2 changed files with 5 additions and 2 deletions
|
@ -64,7 +64,7 @@ class DomainSecurityEmailForm(forms.Form):
|
|||
|
||||
"""Form for adding or editing a security email to a domain."""
|
||||
|
||||
security_email = forms.EmailField(label="Security email")
|
||||
security_email = forms.EmailField(label="Security email", required=False)
|
||||
|
||||
|
||||
class DomainOrgNameAddressForm(forms.ModelForm):
|
||||
|
|
|
@ -625,7 +625,10 @@ class Domain(TimeStampedModel, DomainHelper):
|
|||
def get_security_email(self):
|
||||
logger.info("get_security_email-> getting the contact ")
|
||||
secContact = self.security_contact
|
||||
return secContact.email
|
||||
if secContact is not None:
|
||||
return secContact.email
|
||||
else:
|
||||
return None
|
||||
|
||||
def clientHoldStatus(self):
|
||||
return epp.Status(state=self.Status.CLIENT_HOLD, description="", lang="en")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue