diff src/memory/memory.py @ 504:65ecbb473cbb

core, quick frontend, plugin xep-0054, bridge: use of memory's entities data for vcard: - bridge: new bridge method getEntityData and signal entityDataUpdated - core: entityDataUpdated signal sent on new string data - quick frontend: fixed avatars/vcard infos, fixed _replace in quick_contact_list - plugin xep-0054: dropped updatedValue signal, use entities data instead
author Goffi <goffi@goffi.org>
date Wed, 26 Sep 2012 01:23:56 +0200
parents 385cd2169eb5
children f98bef71a918
line wrap: on
line diff
--- a/src/memory/memory.py	Wed Sep 26 00:38:41 2012 +0200
+++ b/src/memory/memory.py	Wed Sep 26 01:23:56 2012 +0200
@@ -720,6 +720,8 @@
             raise exceptions.ProfileNotInCacheError
         entity_data = self.entitiesCache[profile].setdefault(entity_jid.userhost(),{})
         entity_data[key] = value
+        if isinstance(value,basestring):
+            self.host.bridge.entityDataUpdated(entity_jid.userhost(), key, value, profile)
 
     def getEntityData(self, entity_jid, keys_list, profile_key):
         """Get a list of cached values for entity
@@ -727,7 +729,7 @@
         @param keys_list: list of keys to get, empty list for everything
         @param profile_key: %(doc_profile_key)s
         @return: dict withs values for each key in keys_list.
-                 if there is no value of a given key, resultint dict will
+                 if there is no value of a given key, resulting dict will
                  have nothing with that key nether
         @raise: exceptions.UnknownEntityError if entity is not in cache
                 exceptions.ProfileNotInCacheError if profile is not in cache