Fix: access forbidden if rowid is empty
This commit is contained in:
parent
0bae0148c1
commit
4bec281dd8
1 changed files with 5 additions and 1 deletions
|
|
@ -56,7 +56,7 @@ $typeid=GETPOST('typeid','int');
|
|||
$userid=GETPOST('userid','int');
|
||||
$socid=GETPOST('socid','int');
|
||||
|
||||
if ($rowid)
|
||||
if ($rowid > 0)
|
||||
{
|
||||
// Load member
|
||||
$result = $object->fetch($rowid);
|
||||
|
|
@ -73,6 +73,10 @@ if ($rowid)
|
|||
|| (($user->id != $adh->user_id) && $user->rights->user->user->password) );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
accessforbidden();
|
||||
}
|
||||
|
||||
// Define variables to know what current user can do on members
|
||||
$canaddmember=$user->rights->adherent->creer;
|
||||
|
|
|
|||
Loading…
Reference in a new issue