diff libervia/backend/plugins/plugin_xep_0373.py @ 4334:111dce64dcb5

plugins XEP-0300, XEP-0446, XEP-0447, XEP0448 and others: Refactoring to use Pydantic: Pydantic models are used more and more in Libervia, for the bridge API, and also to convert `domish.Element` to internal representation. Type hints have also been added in many places. rel 453
author Goffi <goffi@goffi.org>
date Tue, 03 Dec 2024 00:12:38 +0100
parents 71c939e34ca6
children 62746042e6d9
line wrap: on
line diff
--- a/libervia/backend/plugins/plugin_xep_0373.py	Tue Dec 03 00:11:00 2024 +0100
+++ b/libervia/backend/plugins/plugin_xep_0373.py	Tue Dec 03 00:12:38 2024 +0100
@@ -787,23 +787,17 @@
                     algorithm=self.ALGORITHM,
                     expires=False,
                     certify=True,
-                    force=True
+                    force=True,
                 )
 
                 primary_key_obj = c.get_key(primary_create_result.fpr, secret=True)
 
                 c.create_subkey(
-                    primary_key_obj,
-                    algorithm=self.ALGORITHM,
-                    expires=False,
-                    sign=True
+                    primary_key_obj, algorithm=self.ALGORITHM, expires=False, sign=True
                 )
 
                 c.create_subkey(
-                    primary_key_obj,
-                    algorithm=self.ALGORITHM,
-                    expires=False,
-                    encrypt=True
+                    primary_key_obj, algorithm=self.ALGORITHM, expires=False, encrypt=True
                 )
             except gpg.errors.GPGMEError as e:
                 raise GPGProviderError("Internal GPGME error") from e