From 6a7456758302ddf94ae4e13e6172b75d64827c7f Mon Sep 17 00:00:00 2001 From: philippe_mingo Date: Sun, 18 Nov 2001 19:28:02 +0000 Subject: [PATCH 1/1] Intl. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@1775 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- plugins/newmail/setup.php | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/plugins/newmail/setup.php b/plugins/newmail/setup.php index 95514c60..94598761 100644 --- a/plugins/newmail/setup.php +++ b/plugins/newmail/setup.php @@ -25,7 +25,7 @@ function CheckNewMailboxSound($imapConnection, $mailbox, $real_box, $delimeter, $unseen, &$total_unseen) { global $folder_prefix, $trash_folder, $sent_folder; - global $color, $move_to_sent, $move_to_trash; + global $color, $move_to_sent, $move_to_trash; global $unseen_notify, $unseen_type, $newmail_allbox, $newmail_recent; global $newmail_changetitle; @@ -34,31 +34,31 @@ // Skip folders for Sent and Trash - if ($real_box == $sent_folder || + if ($real_box == $sent_folder || $real_box == $trash_folder) { - return 0; + return 0; } if (($unseen_notify == 2 && $real_box == 'INBOX') || ($unseen_notify == 3 && ($newmail_allbox == 'on' || - $real_box == 'INBOX'))) { + $real_box == 'INBOX'))) { $unseen = sqimap_unseen_messages($imapConnection, $real_box); - $total_unseen += $unseen; - - if($newmail_recent == 'on') { - $unseen = sqimap_mailbox_select( $imapConnection, $real_box, TRUE, TRUE); - } - + $total_unseen += $unseen; + + if($newmail_recent == 'on') { + $unseen = sqimap_mailbox_select( $imapConnection, $real_box, TRUE, TRUE); + } + if ($unseen > 0) { $unseen_found = 1; - } + } } return( $unseen_found ); } function squirrelmail_plugin_init_newmail() { global $squirrelmail_plugin_hooks; - + $squirrelmail_plugin_hooks['left_main_before']['newmail'] = 'newmail_plugin'; $squirrelmail_plugin_hooks['optpage_register_block']['newmail'] = 'newmail_optpage_register_block'; $squirrelmail_plugin_hooks['options_link_and_description']['newmail'] = 'newmail_options'; -- 2.25.1