diff options
| author | J08nY | 2017-06-15 23:23:19 +0200 |
|---|---|---|
| committer | J08nY | 2017-06-15 23:23:19 +0200 |
| commit | b86dbc83db1f85146ec48866b6ada4f1bb8d41c0 (patch) | |
| tree | a290124e75e283d88c75a5cb87d8d217385c0e2f /src/mailman_pgp/model/list.py | |
| parent | c649aa7e8102899e2018242f68860ae350af3905 (diff) | |
| download | mailman-pgp-b86dbc83db1f85146ec48866b6ada4f1bb8d41c0.tar.gz mailman-pgp-b86dbc83db1f85146ec48866b6ada4f1bb8d41c0.tar.zst mailman-pgp-b86dbc83db1f85146ec48866b6ada4f1bb8d41c0.zip | |
Diffstat (limited to 'src/mailman_pgp/model/list.py')
| -rw-r--r-- | src/mailman_pgp/model/list.py | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/mailman_pgp/model/list.py b/src/mailman_pgp/model/list.py index f781a9a..d6384af 100644 --- a/src/mailman_pgp/model/list.py +++ b/src/mailman_pgp/model/list.py @@ -13,7 +13,7 @@ class EncryptedMailingList(Base): __tablename__ = 'encrypted_lists' id = Column(Integer, primary_key=True) - list_id = Column(SAUnicode) + list_id = Column(SAUnicode, index=True) key_fingerprint = Column(SAUnicode) unsigned_msg_action = Column(Enum(Action)) nonencrypted_msg_action = Column(Enum(Action)) @@ -21,4 +21,12 @@ class EncryptedMailingList(Base): sign_outgoing = Column(Boolean) def __init__(self, mlist): + super().__init__() self.list_id = mlist.list_id + self._list_key = None + + @property + def list_key(self): + if self._list_key is not None: + return self._list_key + pass |
