aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/groupwise-features/share-folder-common.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/groupwise-features/share-folder-common.c')
-rw-r--r--plugins/groupwise-features/share-folder-common.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/plugins/groupwise-features/share-folder-common.c b/plugins/groupwise-features/share-folder-common.c
index 3adb7542e5..20720e916c 100644
--- a/plugins/groupwise-features/share-folder-common.c
+++ b/plugins/groupwise-features/share-folder-common.c
@@ -66,18 +66,16 @@ static void refresh_folder_tree (EMFolderTreeModel *model, CamelStore *store);
static void
refresh_folder_tree (EMFolderTreeModel *model, CamelStore *store)
{
- gchar *uri;
EAccount *account;
CamelProvider *provider;
- CamelURL *url;
+ const gchar *uid;
+ gchar *uri;
- url = camel_service_get_camel_url (CAMEL_SERVICE (store));
- uri = camel_url_to_string (url, CAMEL_URL_HIDE_ALL);
+ uid = camel_service_get_uid (CAMEL_SERVICE (store));
+ account = e_get_account_by_uid (uid);
- account = e_get_account_by_source_url (uri);
- if (!account) {
+ if (account == NULL)
return;
- }
uri = account->source->url;
em_folder_tree_model_remove_store (model, store);
@@ -89,7 +87,6 @@ refresh_folder_tree (EMFolderTreeModel *model, CamelStore *store)
if (!(provider->flags & CAMEL_PROVIDER_IS_STORAGE))
return;
em_folder_tree_model_add_store (model, store, account->name);
- /* g_object_unref (store); */
}
void