From 2dc7af10fbb3edd54bbdc3b0d65c6728078fa4b7 Mon Sep 17 00:00:00 2001 From: mathieui Date: Sun, 29 Jan 2012 03:34:01 +0100 Subject: [PATCH] Do not traceback when /gpg outside a ConversationTab --- plugins/gpg/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/gpg/__init__.py b/plugins/gpg/__init__.py index 01ca6ab2..620a4589 100644 --- a/plugins/gpg/__init__.py +++ b/plugins/gpg/__init__.py @@ -176,6 +176,8 @@ class Plugin(BasePlugin): else: if isinstance(self.core.current_tab(), ConversationTab): jid = JID(self.core.current_tab().get_name()) + else: + return command = args[0] if command == 'force' or command == 'enable': # we can force encryption only with contact having an associated