]> git.0d.be Git - empathy.git/commitdiff
Add individuals to the EmpathyIndividualStore before updating them
authorPhilip Withnall <philip.withnall@collabora.co.uk>
Wed, 15 Sep 2010 15:22:30 +0000 (16:22 +0100)
committerPhilip Withnall <philip.withnall@collabora.co.uk>
Wed, 15 Sep 2010 15:24:26 +0000 (16:24 +0100)
When adding a new contact _with_ an alias set, the code in
EmpathyIndividualStore was listening to (and acting on) property notifications
(such as alias changes) for the individual before adding the individual to the
store, resulting in duplicate contact listings. Closes: bgo#629380

libempathy-gtk/empathy-individual-store.c

index 985b6e317feb877ba13a6b93169e70ef5a5ab85f..77f3016ecc1755d3c564f333cb1f893bd556d076 100644 (file)
@@ -874,6 +874,8 @@ static void
 individual_store_add_individual_and_connect (EmpathyIndividualStore *self,
     FolksIndividual *individual)
 {
+  individual_store_add_individual (self, individual);
+
   g_signal_connect (individual, "notify::avatar",
       (GCallback) individual_store_individual_updated_cb, self);
   g_signal_connect (individual, "notify::presence-type",
@@ -887,7 +889,6 @@ individual_store_add_individual_and_connect (EmpathyIndividualStore *self,
 
   individual_personas_changed_cb (individual,
       folks_individual_get_personas (individual), NULL, self);
-  individual_store_add_individual (self, individual);
 }
 
 static void