Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/python-nbxmpp.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlovetox <philipp@hoerist.com>2020-03-11 01:10:01 +0300
committerlovetox <philipp@hoerist.com>2020-03-11 01:20:09 +0300
commit24e1bf2c910fec7da04534de7a188769dfcf970c (patch)
tree63b56e25a1a9e641f7fab7ed3fdf751ddcc0cfcc /nbxmpp/modules
parenteabe1064b64438b6d9ea4ba4db44cd1ef76c9d27 (diff)
Fix pylint errors
- no-else-return - pointless-string-statement - multiple-statements - unused-variable - wrong-import-position
Diffstat (limited to 'nbxmpp/modules')
-rw-r--r--nbxmpp/modules/openpgp.py19
1 files changed, 10 insertions, 9 deletions
diff --git a/nbxmpp/modules/openpgp.py b/nbxmpp/modules/openpgp.py
index 0b2978d..40e3d14 100644
--- a/nbxmpp/modules/openpgp.py
+++ b/nbxmpp/modules/openpgp.py
@@ -81,13 +81,7 @@ class OpenPGP:
return
def _process_pubsub_openpgp(self, _client, stanza, properties):
- if not properties.is_pubsub_event:
- return
-
- if properties.pubsub_event.node != NS_OPENPGP_PK:
- return
-
- '''
+ """
<item>
<public-keys-list xmlns='urn:xmpp:openpgp:0'>
<pubkey-metadata
@@ -99,8 +93,15 @@ class OpenPGP:
date='1953-05-16T12:00:00Z'
/>
</public-keys-list>
- </item>
- '''
+ </item>
+ """
+
+ if not properties.is_pubsub_event:
+ return
+
+ if properties.pubsub_event.node != NS_OPENPGP_PK:
+ return
+
item = properties.pubsub_event.item
if item is None:
# Retract, Deleted or Purged