[evolution-data-server] gnome_online_accounts_get_backend_name() cleanups.
- From: Matthew Barnes <mbarnes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server] gnome_online_accounts_get_backend_name() cleanups.
- Date: Mon, 28 Jan 2013 17:19:03 +0000 (UTC)
commit 6f65f3b04db470ad4c6379617d25329f967b73b3
Author: Matthew Barnes <mbarnes redhat com>
Date: Mon Jan 28 12:05:21 2013 -0500
gnome_online_accounts_get_backend_name() cleanups.
.../module-gnome-online-accounts.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/modules/gnome-online-accounts/module-gnome-online-accounts.c b/modules/gnome-online-accounts/module-gnome-online-accounts.c
index 0a2136a..4c57bc8 100644
--- a/modules/gnome-online-accounts/module-gnome-online-accounts.c
+++ b/modules/gnome-online-accounts/module-gnome-online-accounts.c
@@ -98,18 +98,20 @@ gnome_online_accounts_get_backend_name (const gchar *goa_provider_type)
{
const gchar *eds_backend_name = NULL;
+ g_return_val_if_fail (goa_provider_type != NULL, NULL);
+
/* This is a mapping between GoaAccount provider types and
* ESourceCollection backend names. It requires knowledge
* of other registry modules, possibly even from 3rd party
* packages. No way around it. */
- if (g_strcmp0 (goa_provider_type, "exchange") == 0)
+ if (g_str_equal (goa_provider_type, "exchange"))
eds_backend_name = "ews";
- if (g_strcmp0 (goa_provider_type, "google") == 0)
+ if (g_str_equal (goa_provider_type, "google"))
eds_backend_name = "google";
- else if (g_strcmp0 (goa_provider_type, "yahoo") == 0)
+ if (g_str_equal (goa_provider_type, "yahoo"))
eds_backend_name = "yahoo";
return eds_backend_name;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]