diff --git a/includes/surveillance/surveillance.php b/includes/surveillance/surveillance.php index 56405472f..300ad41f1 100644 --- a/includes/surveillance/surveillance.php +++ b/includes/surveillance/surveillance.php @@ -100,8 +100,7 @@ function getSurveillance($page, $siret){ 'dirigeants' => 'dirigeants', ); $return = ''; - $firephp->log($_SESSION,'SESSION'); - if(preg_match('/'.$assocPageDroit[$page].'\b/i', $_SESSION['tabInfo']['droits'])) + if(is_string($page) && array_key_exists($page, $assocPageDroit) && preg_match('/'.$assocPageDroit[$page].'\b/i', $_SESSION['tabInfo']['droits'])) { if( preg_match('/voirsurv\b/i', $_SESSION['tabInfo']['pref']) && inSurveillance($assocPageSource[$page], $siret))