diff options
author | Philipp Hörist <forenjunkie@chello.at> | 2017-06-11 00:32:30 +0300 |
---|---|---|
committer | Philipp Hörist <forenjunkie@chello.at> | 2017-06-11 00:32:30 +0300 |
commit | fc5a1035794effd3d330b2593a1a9dc0b7f4fa02 (patch) | |
tree | 11f991d715cf665948734c2e8f1d697007a6a04e /pgp | |
parent | f41a747e578e3dab652049c437a536e052f8e4a4 (diff) |
[pgp] Modify event obj only if we encrypt
Diffstat (limited to 'pgp')
-rw-r--r-- | pgp/pgpplugin.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/pgp/pgpplugin.py b/pgp/pgpplugin.py index ed87bf8..27ee338 100644 --- a/pgp/pgpplugin.py +++ b/pgp/pgpplugin.py @@ -229,6 +229,7 @@ class OldPGPPlugin(GajimPlugin): None, conn=conn, jid=obj.jid, message=obj.message, error=error, time_=time.time(), session=obj.session)) return + self.cleanup_stanza(obj) if msgenc: @@ -240,10 +241,11 @@ class OldPGPPlugin(GajimPlugin): 'namespace': nbxmpp.NS_ENCRYPTED}) obj.msg_iq.addChild(node=eme_node) - # Set xhtml to None so it doesnt get logged - obj.xhtml = None - obj.encrypted = self.encryption_name - print_msg_to_log(obj.msg_iq) + # Set xhtml to None so it doesnt get logged + obj.xhtml = None + obj.encrypted = self.encryption_name + print_msg_to_log(obj.msg_iq) + callback(obj) def encrypt_file(self, file, account, callback): |