Changeset 991


Ignore:
Timestamp:
06/16/09 10:00:28 (15 years ago)
Author:
niltonneto
Message:

Ticket #505 - Correção do jid do contato. Sem dominio quando é de outra OU.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/jabberit_messenger/inc/class.contacts_im.inc.php

    r988 r991  
    6969                // Hosts Jabber 
    7070                $hostsJabber = unserialize($_SESSION['phpgw_info']['jabberit_messenger']['map_org_realm_jabberit']); 
    71  
    72                 foreach($hostsJabber as $conf ) 
    73                         if( array_search("*", $conf) ) 
    74                                 $hostDefault = $conf['jabberName']; 
    7571                         
    7672                if( is_array($users) ) 
     
    8278                                        foreach($hostsJabber as $itens) 
    8379                                        { 
    84                                                 if( trim($users[$i]['ou']) === trim($itens['org']) ) 
    85                                                         $users[$i]['jid'] = $users[$i]['jid']."@".$itens['jabberName']; 
     80                                                if( trim($users[$i]['ou']) === trim($itens['org']) && strpos($users[$i]['jid'],"@") === false) 
     81                                                                $users[$i]['jid'] = $users[$i]['jid']."@".$itens['jabberName'];                                          
    8682                                                else 
    8783                                                { 
    88                                                         if( $users[$i]['ou'] === $ou_User ) 
    89                                                                 if(strpos($users[$i]['jid'],"@") === false) 
     84                                                        if(strpos($users[$i]['jid'],"@") === false) 
    9085                                                                        $users[$i]['jid'] = $users[$i]['jid']."@".$this->serverJabber; 
    91                                                         else 
    92                                                                 if(strpos($users[$i]['jid'],"@") === false) 
    93                                                                         $users[$i]['jid'] = $users[$i]['jid']."@".$hostDefault; 
    9486                                                } 
    9587                                        } 
Note: See TracChangeset for help on using the changeset viewer.