aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-utils.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2011-05-06 02:07:33 +0800
committerMatthew Barnes <mbarnes@redhat.com>2011-05-06 03:20:23 +0800
commit3433cca045b1f59ec026d16790ff6c604edf3463 (patch)
tree9df2ccd91db17c82b1a9b134d9cc03bc7da8f007 /mail/em-utils.c
parent03315463529dd850639984f79b014c9486f2230a (diff)
downloadgsoc2013-evolution-3433cca045b1f59ec026d16790ff6c604edf3463.tar.gz
gsoc2013-evolution-3433cca045b1f59ec026d16790ff6c604edf3463.tar.zst
gsoc2013-evolution-3433cca045b1f59ec026d16790ff6c604edf3463.zip
Simplify em_utils_folder_is_sent().
e_mail_folder_uri_equal() uses e_mail_folder_uri_parse() to parse both URIs, so we can just hand it an 'email://' URI directly.
Diffstat (limited to 'mail/em-utils.c')
-rw-r--r--mail/em-utils.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/mail/em-utils.c b/mail/em-utils.c
index 7efa1df32c..14a8706c21 100644
--- a/mail/em-utils.c
+++ b/mail/em-utils.c
@@ -1144,17 +1144,12 @@ em_utils_folder_is_sent (CamelFolder *folder)
EAccount *account;
/* XXX EIterator misuses const. */
- account = (EAccount *)e_iterator_get (iterator);
-
- if (account->sent_folder_uri) {
- gchar *sent_uri;
+ account = (EAccount *) e_iterator_get (iterator);
- sent_uri = em_uri_to_camel (
- account->sent_folder_uri);
+ if (account->sent_folder_uri != NULL)
is_sent = e_mail_folder_uri_equal (
- session, sent_uri, folder_uri);
- g_free (sent_uri);
- }
+ session, folder_uri,
+ account->sent_folder_uri);
e_iterator_next (iterator);
}