paperwork: Only return a list name for departments with the flag

This commit is contained in:
Adam Goldsmith 2023-02-02 14:51:39 -05:00
parent bb0e5abad5
commit 86000be17b

View File

@ -72,7 +72,10 @@ class Department(models.Model):
@property @property
def list_name(self): def list_name(self):
if self.has_mailing_list:
return self.name.replace(" ", "_") + "-info" return self.name.replace(" ", "_") + "-info"
else:
return None
class CertificationDefinition(models.Model): class CertificationDefinition(models.Model):