Commit 6e1154c0 authored by Bate's avatar Bate

Les non connectes n'ont pas droit que de lire les fichiers

parent 63910d57
......@@ -105,12 +105,17 @@ abstract class basedb extends stdentity
function is_right ( &$user, $required )
{
if(!$user->is_valid()) {
if($required == DROIT_LECTURE && (($required & $this->droits_access) == $required))
return true;
else
return false;
}
if(!$user->is_valid()) {
echo "Droits: $required vs ".($required & $this->droits_access);
if($required == DROIT_LECTURE && (($required & $this->droits_access) == $required))
{
return true;
}
else
{
return false;
}
}
if ( $this->is_admin($user)) return true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment