[gnome-online-accounts] tplinker: ignore chat accounts handled by other providers



commit df3daeb0a8a9d2118710b8dd59ee874a270e4cd4
Author: Marco Barisione <marco barisione collabora co uk>
Date:   Fri Jul 19 08:13:42 2013 +0100

    tplinker: ignore chat accounts handled by other providers
    
    We don't want chat accounts handled by other providers (like Facebook or
    Google ones) to appear twice, once through the “telepathy” provider and
    once through the service-specific one.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=696267

 src/daemon/goatpaccountlinker.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/src/daemon/goatpaccountlinker.c b/src/daemon/goatpaccountlinker.c
index d96592a..4a282d2 100644
--- a/src/daemon/goatpaccountlinker.c
+++ b/src/daemon/goatpaccountlinker.c
@@ -207,6 +207,13 @@ tp_account_added (GoaTpAccountLinker *self,
   const gchar *id = get_id_from_tp_account (tp_account);
   GoaObject *goa_object = NULL;
 
+  if (g_strcmp0 (tp_account_get_storage_provider (tp_account),
+        "org.gnome.OnlineAccounts") == 0)
+    {
+      goa_debug ("Skipping Telepathy account %s as it's handled directly by GOA", id);
+      return;
+    }
+
   goa_debug ("Telepathy account found: %s", id);
 
   g_hash_table_replace (priv->tp_accounts, g_strdup (id),


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]