Liveuser Issue

From: Date: Sun, 07 Dec 2003 18:16:35 +0000
Subject: Liveuser Issue
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-9347@lists.php.net to get a copy of this message
Hallo *, I use LiveUser 0.9 in my application. I haven an problem if removing an user. Folloing Error occurs by removing User: *Warning*: Missing argument 2 for removeuserareaadmin() in */var/www/html/tux/var/packages/LiveUser/Admin/Perm/DB_Common.php* on line *1490* This is in conteyt of following Code: require 'LiveUser/Admin/Auth/Container/DB.php'; require 'LiveUser/Admin/Perm/Container/DB_Complex.php'; class admin_UserPermissionManager { /**
    * Constructor of the class and initiator of perm/user/db Class
    *
    * @access public
    * @param array DB Connection string
    * @param array PermContainer
    * @param object AuthContainer
    */    function admin_UserPermissionManager( $dsn, $permcontainer, $authcontainer ) {
       // PERMISSION Object
       $this->perm =& new LiveUser_Admin_Perm_Container_DB_Complex( $dsn, $permcontainer );
             // USER Object
       $this->user =& new LiveUser_Admin_Auth_Container_DB( $dsn, $authcontainer );
             // DATABASE Object
       $this->db = $this->user->dbc;
       if ( is_object($this->db) ) {
           $this->db->setFetchMode(DB_FETCHMODE_ASSOC);
       }
} /**
    * Delete a user from System
    * @access public
    * @param int $auth_user_id
    * @param int $perm_user_id
    * @param string $perm_user_type
    * @return bool
    */
function deleteUser( $auth_user_id, $perm_user_id, $perm_user_type ) {
       // Delete from txcm_userdata
       $this->db->query('    DELETE
                           FROM
                               txcm_userdata
                           WHERE
                               auth_user_id='.$auth_user_id.'
                           AND
                               perm_user_id='.$perm_user_id.'
                       ');
             // remove from Auth Container
       $this->user->removeUser( $auth_user_id );
             // remove from Perm Container
       $this->perm->removeUser( $auth_user_id );
             //remove user from group
       if ( $perm_user_type == "admin" ) {
           $this->perm->removeUserFromGroup( $auth_user_id, 8 );
       } else {
           $this->perm->removeUserFromGroup( $auth_user_id, 10 );
       }
   }  
The error comes by removing the user from Perm Container: $this->perm->removeUser($auth_user_id );
At first I thought this only happen if user have status ADMIN but it happen as well if status is USER.
May someone can help me here, Cheers -Peter

« previous php.pear.general (#9347) next »