Le profil des memebrs sans profil (bannis, visiteurs et admin, vaut 0)

This commit is contained in:
Fred Tempez 2023-07-05 17:58:01 +02:00
parent f915c591fa
commit 0fe4c582a1
1 changed files with 4 additions and 4 deletions

View File

@ -98,8 +98,8 @@ class user extends common
// Profil // Profil
$group = $this->getInput('userAddGroup', helper::FILTER_INT, true); $group = $this->getInput('userAddGroup', helper::FILTER_INT, true);
$profil = null; $profil = 0;
if ($group > 1 || $group < 2) { if ($group === 1 || $group === 2) {
$profil = $this->getInput('userAddProfil' . $group, helper::FILTER_INT); $profil = $this->getInput('userAddProfil' . $group, helper::FILTER_INT);
} }
@ -303,8 +303,8 @@ class user extends common
$newlastname = $this->getData(['user', $this->getUrl(2), 'lastname']); $newlastname = $this->getData(['user', $this->getUrl(2), 'lastname']);
} }
// Profil // Profil
$profil = null; $profil = 0;
if ($newGroup > 1 || $newGroup < 2) { if ($newGroup === 1 || $newGroup === 2) {
$profil = $this->getInput('userEditProfil' . $newGroup, helper::FILTER_INT); $profil = $this->getInput('userEditProfil' . $newGroup, helper::FILTER_INT);
} }
// Modifie l'utilisateur // Modifie l'utilisateur