telepathy: Keep Tpf.PersonaStore.personas up to date for cached stores
authorPhilip Withnall <philip@tecnocode.co.uk>
Fri, 6 Jan 2012 23:08:10 +0000 (23:08 +0000)
committerPhilip Withnall <philip@tecnocode.co.uk>
Mon, 9 Jan 2012 11:26:45 +0000 (11:26 +0000)
When loading a Tpf.PersonaStore from its cache, ensure Personas are inserted
into both the set of personas _and_ the map of IIDs to personas.

This fixes Tpf.PersonaStore.personas being empty for cached stores.

Helps: https://bugzilla.gnome.org/show_bug.cgi?id=667410

backends/telepathy/lib/tpf-persona-store.vala

index d905da2..f8e1ace 100644 (file)
@@ -1080,6 +1080,7 @@ public class Tpf.PersonaStore : Folks.PersonaStore
         {
           foreach (var p in cached_personas)
             {
+              this._personas.set (p.iid, p);
               this._persona_set.add (p);
             }
         }