]> git.0d.be Git - empathy.git/commitdiff
Don't need to check twice if location has latitude
authorPierre-Luc Beaudoin <pierre-luc@pierlux.com>
Wed, 27 May 2009 16:09:52 +0000 (12:09 -0400)
committerPierre-Luc Beaudoin <pierre-luc@pierlux.com>
Wed, 27 May 2009 16:52:10 +0000 (12:52 -0400)
There is no need to check for lon as lat, lon as always set togeter (they
are meaningless alone).

libempathy/empathy-tp-contact-factory.c

index cd7824a7a88f9af8543ac3e73fde7c202abc490a..cfdbf8c941077d058e4b0a148155c9a6c57bdcff 100644 (file)
@@ -511,7 +511,6 @@ tp_contact_factory_geocode (EmpathyContact *contact)
                geocode_cb, contact);
 
        g_hash_table_unref (address);
-       return;
 #endif
 }
 
@@ -522,7 +521,6 @@ tp_contact_factory_update_location (EmpathyTpContactFactory *tp_factory,
 {
        EmpathyContact *contact;
        GHashTable     *new_location;
-       GValue         *value;
 
        contact = tp_contact_factory_find_by_handle (tp_factory, handle);
 
@@ -536,10 +534,7 @@ tp_contact_factory_update_location (EmpathyTpContactFactory *tp_factory,
        empathy_contact_set_location (contact, new_location);
        g_hash_table_unref (new_location);
 
-       value = g_hash_table_lookup (location, EMPATHY_LOCATION_LAT);
-       if (value == NULL) {
-               tp_contact_factory_geocode (contact);
-       }
+       tp_contact_factory_geocode (contact);
 }
 
 static void