aboutsummaryrefslogtreecommitdiff
path: root/src/mailman_pgp/model/list.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/mailman_pgp/model/list.py')
-rw-r--r--src/mailman_pgp/model/list.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mailman_pgp/model/list.py b/src/mailman_pgp/model/list.py
index eccb28a..001b6b3 100644
--- a/src/mailman_pgp/model/list.py
+++ b/src/mailman_pgp/model/list.py
@@ -26,6 +26,7 @@ class EncryptedMailingList(Base):
def __init__(self, mlist):
super().__init__()
self.list_id = mlist.list_id
+ self._mlist = mlist
self._pubkey = None
self._key_generator = self._create_generator(mlist)
@@ -50,6 +51,8 @@ class EncryptedMailingList(Base):
@property
def mlist(self):
+ if self._mlist is not None:
+ return self._mlist
return mailman_config.db.query(MailingList).filter_by(
_list_id=self.list_id).first()