diff options
Diffstat (limited to 'mail/em-composer-utils.c')
-rw-r--r-- | mail/em-composer-utils.c | 34 |
1 files changed, 2 insertions, 32 deletions
diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c index 33972e1222..81055d1ab0 100644 --- a/mail/em-composer-utils.c +++ b/mail/em-composer-utils.c @@ -1844,19 +1844,6 @@ reply_get_composer (CamelMimeMessage *message, EAccount *account, } static EAccount * -guess_account_folder(CamelFolder *folder) -{ - EAccount *account; - gchar *tmp; - - tmp = camel_url_to_string(CAMEL_SERVICE(folder->parent_store)->url, CAMEL_URL_HIDE_ALL); - account = mail_config_get_account_by_source_url(tmp); - g_free(tmp); - - return account; -} - -static EAccount * guess_account (CamelMimeMessage *message, CamelFolder *folder) { GHashTable *account_hash = NULL; @@ -1868,27 +1855,10 @@ guess_account (CamelMimeMessage *message, CamelFolder *folder) CAMEL_RECIPIENT_TYPE_CC }; - /* check for newsgroup header */ - if (folder - && camel_medium_get_header((CamelMedium *)message, "Newsgroups") - && (account = guess_account_folder(folder))) + account = em_utils_guess_account (message, folder); + if (account) return account; - /* check for source folder */ - if (folder) { - account = guess_account_folder(folder); - if (account) - return account; - } - - /* then message source */ - if (account == NULL - && (tmp = camel_mime_message_get_source(message))) { - account = mail_config_get_account_by_source_url(tmp); - if (account) - return account; - } - /* finally recipient (to/cc) in account table */ account_hash = generate_account_hash (); for (j=0;account == NULL && j<2;j++) { |