diff options
Diffstat (limited to 'src/mailman_pgp/commands/eml_key.py')
| -rw-r--r-- | src/mailman_pgp/commands/eml_key.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mailman_pgp/commands/eml_key.py b/src/mailman_pgp/commands/eml_key.py index 15db0b1..fbae25e 100644 --- a/src/mailman_pgp/commands/eml_key.py +++ b/src/mailman_pgp/commands/eml_key.py @@ -65,8 +65,11 @@ def _cmd_set(pgp_list, mlist, msg, msgdata, arguments, results): print('No adddress to subscribe with.', file=results) return ContinueProcessing.no + with transaction() as t: - pgp_address = PGPAddress(address) + pgp_address = PGPAddress.for_address(address) + if pgp_address is None: + pgp_address = PGPAddress(address) pgp_address.key = keys.pop() t.add(pgp_address) |
