Changeset 5539 in subversion


Ignore:
Timestamp:
Dec 4, 2011 11:56:04 AM (18 months ago)
Author:
thomasb
Message:

Accept contact IDs as array or comma-separated string

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/roundcubemail/program/include/rcube_ldap.php

    r5524 r5539  
    10281028 
    10291029        // add new contact to the selected group 
    1030         if ($this->groups) 
     1030        if ($this->group_id) 
    10311031            $this->add_to_group($this->group_id, $dn); 
    10321032 
     
    17231723            $group_cache = $this->_fetch_groups(); 
    17241724 
     1725        if (!is_array($contact_ids)) 
     1726            $contact_ids = explode(',', $contact_ids); 
     1727 
    17251728        $base_dn     = $this->groups_base_dn; 
    17261729        $group_name  = $group_cache[$group_id]['name']; 
     
    17291732 
    17301733        $new_attrs = array(); 
    1731         foreach (explode(",", $contact_ids) as $id) 
     1734        foreach ($contact_ids as $id) 
    17321735            $new_attrs[$member_attr][] = self::dn_decode($id); 
    17331736 
Note: See TracChangeset for help on using the changeset viewer.