This patch just lists the accounts that were created with the default 'imap' driver for fetching within IMP. I think it might be better in the long run to add another variable to the preference array that says whether or not this particular account should be available (or maybe 'enabled'?) for IMP to Fetch.

For Example, the drivers I've added are for FetchYahoo and GotMail ('web' driver), and IMAPSync. These are all external to IMP, do not really conform to the standard account setup template, and don't run within IMP.

I'm not entirely sure how, or if, these patches fit with mainstream IMP, but here it is again :)

--- /usr/local/www/data/horde/imp/fetchmail.php Fri Jun 13 18:55:34 2008
+++ /usr/local/www/sub/beta/horde/imp/fetchmail.php Sun Dec 7 16:08:17 2008
@@ -66,10 +66,13 @@
if ($accounts) {
    $accountsval = array();
    foreach (array_keys($accounts) as $key) {
-        $accountsval[] = array(
-            'key' => $key,
-            'label' => htmlspecialchars($fm_account->getValue('id', $key))
-        );
+ if ( preg_match("/imap/i" , $fm_account->getValue('driver', $key) ) ){
+            $accountsval[] = array(
+                'key' => $key,
+ 'label' => htmlspecialchars($fm_account->getValue('id', $key))
+             );
+       }
+
    }
    $t->set('accounts', $accountsval);
}


--
IMP mailing list - Join the hunt: http://horde.org/bounties/#imp
Frequently Asked Questions: http://horde.org/faq/
To unsubscribe, mail: [EMAIL PROTECTED]

Reply via email to