Make message details link a non-relative URI. Thanks Thierry Godefroy
[squirrelmail.git] / functions / identity.php
index b2b82177321ae72d1ceccb3d2e6de3dbf3a0b459..79576ab84807ee02b92cedf47990c858a6875256 100644 (file)
@@ -135,7 +135,8 @@ function sqfixidentities( $identities, $id, $action ) {
                     $fixed[0] = $ident;
 
                     // inform plugins about renumbering of ids
-                    do_hook('options_identities_renumber', $temp=array(&$id, 'default'));
+                    $temp = array(&$id, 'default');
+                    do_hook('options_identities_renumber', $temp);
 
                     continue 2;
                 } else {
@@ -149,7 +150,8 @@ function sqfixidentities( $identities, $id, $action ) {
                     $tmp_hold = $ident;
 
                     // inform plugins about renumbering of ids
-                    do_hook('options_identities_renumber', $temp=array(&$id , $id - 1));
+                    $temp = array(&$id , $id - 1);
+                    do_hook('options_identities_renumber', $temp);
 
                     continue 2;
                 } else {
@@ -166,7 +168,8 @@ function sqfixidentities( $identities, $id, $action ) {
 
                 if ($key == $id) {
                     // inform plugins about deleted id
-                    do_hook('options_identities_process', $temp=array(&$action, &$id));
+                    $temp = array(&$action, &$id);
+                    do_hook('options_identities_process', $temp);
 
                     continue 2;
                 } else {
@@ -182,7 +185,8 @@ function sqfixidentities( $identities, $id, $action ) {
                  * be used to detect modified hook. Older hook does not
                  * provide information that can be useful for plugins.
                  */
-                do_hook('options_identities_process', $temp=array(&$action, &$id));
+                $temp = array(&$action, &$id);
+                do_hook('options_identities_process', $temp);
 
                 $fixed[$i] = $ident;
 
@@ -257,7 +261,7 @@ function find_identity($needles) {
     foreach ( $idents as $nr => $ident ) {
         if ( isset($ident['email_address']) ) {
             foreach ( $needles as $needle ) {
-                if ( $needle == $ident['email_address'] ) {
+                if ( strcasecmp($needle, $ident['email_address']) == 0 ) {
                     return $nr;
                 }
             }