PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » Authentication » LiveUser » Bug #365

Duplicate code in LiveUser_Admin_Perm_DB_Common::removeUser()

Details

Submitted2003-12-05 23:48 UTC
Fromkipaten21 at hotmail dot com
Assignedlsmith
StatusClosed
PackageLiveUser
PHP VersionIrrelevant
OSANY
Roadmaps(Not assigned)

Comments

[2003-12-05 23:48 UTC] kipaten21 at hotmail dot com

Description:
------------
There is code to remove a user's rights upon removing a user that is duplicated twice in the LiveUser_Admin_Perm_DB_Common::removeUser() method.

function removeUser($authId)
{
<snip>
// Delete user's rights (Perm/DB)
$query = '
DELETE FROM
' . $this->prefix . 'userrights
WHERE
perm_user_id = ' . $permId;

$result = $this->dbc->query($query);

if (DB::isError($result)) {
return $result;
}
<snip>
// Delete right assignments
$query = 'DELETE FROM
' . $this->prefix . 'userrights
WHERE
perm_user_id = ' . $permId;

$result = $this->dbc->query($query);

if (DB::isError($result)) {
return $result;
};
<snip>
}