From 9eff396227afa37f3fb9af9610e7cdd72d86bf14 Mon Sep 17 00:00:00 2001 From: Tanguy Ortolo Date: Tue, 29 Nov 2016 21:30:48 +0100 Subject: Fix inexistent method calls in the gpg plugin The gpg plugin tries to call Presence.find() and Message.find(), that do not exist. The correct calls are Presence.xml.find() and Message.xml.find(). --- plugins/gpg/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'plugins') diff --git a/plugins/gpg/__init__.py b/plugins/gpg/__init__.py index daf76e65..0282c93a 100644 --- a/plugins/gpg/__init__.py +++ b/plugins/gpg/__init__.py @@ -202,7 +202,7 @@ class Plugin(BasePlugin): add 'valid' or 'invalid' into the dict. If it cannot be verified, just add 'signed'. Otherwise, do nothing. """ - signed = presence.find('{%s}x' % (NS_SIGNED,)) + signed = presence.xml.find('{%s}x' % (NS_SIGNED,)) bare = presence['from'].bare full = presence['from'].full if signed is None: @@ -264,7 +264,7 @@ class Plugin(BasePlugin): """ Check if the message is encrypted, and decrypt it if we can. """ - encrypted = message.find('{%s}x' % (NS_ENCRYPTED,)) + encrypted = message.xml.find('{%s}x' % (NS_ENCRYPTED,)) fro = message['from'] if encrypted is not None: if self.config.has_section('keys') and fro.bare in self.config.options('keys'): -- cgit v1.2.3