diff src/plugins/plugin_xep_0054.py @ 939:01342bfe9f41

wix: fixed onShowProfile
author Goffi <goffi@goffi.org>
date Thu, 27 Mar 2014 10:36:20 +0100
parents 1a759096ccbd
children c6d8fc63b1db
line wrap: on
line diff
--- a/src/plugins/plugin_xep_0054.py	Thu Mar 27 02:24:20 2014 +0100
+++ b/src/plugins/plugin_xep_0054.py	Thu Mar 27 10:36:20 2014 +0100
@@ -21,8 +21,7 @@
 from sat.core.i18n import _
 from sat.core.constants import Const as C
 from logging import debug, info, error
-from twisted.internet import threads
-from twisted.internet.defer import inlineCallbacks, returnValue
+from twisted.internet import threads, defer
 from twisted.words.protocols.jabber import jid
 from twisted.words.protocols.jabber.xmlstream import IQ
 from twisted.words.xish import domish
@@ -156,7 +155,7 @@
                     debug(_("file [%s] already in cache") % image_hash)
                 return image_hash
 
-    @inlineCallbacks
+    @defer.inlineCallbacks
     def vCard2Dict(self, vcard, target, profile):
         """Convert a VCard to a dict, and save binaries"""
         debug(_("parsing vcard"))
@@ -183,7 +182,7 @@
             else:
                 info(_('FIXME: [%s] VCard tag is not managed yet') % elem.name)
 
-        returnValue(dictionary)
+        defer.returnValue(dictionary)
 
     def vcard_ok(self, answer, profile):
         """Called after the first get IQ"""