From 17f82035a3595edb753de3162c3fcb9d0d13cbb7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20France?= Date: Mon, 11 Nov 2024 20:00:59 +0100 Subject: [PATCH] fix phpstan --- build/phpstan/phpstan-baseline.neon | 24 ------------------------ htdocs/public/agenda/agendaexport.php | 8 +++++++- 2 files changed, 7 insertions(+), 25 deletions(-) diff --git a/build/phpstan/phpstan-baseline.neon b/build/phpstan/phpstan-baseline.neon index 3fb9cc39b901a..e00144762296b 100644 --- a/build/phpstan/phpstan-baseline.neon +++ b/build/phpstan/phpstan-baseline.neon @@ -31518,36 +31518,12 @@ parameters: count: 2 path: ../../htdocs/public/agenda/agendaexport.php - - - message: '#^Variable \$conf might not be defined\.$#' - identifier: variable.undefined - count: 3 - path: ../../htdocs/public/agenda/agendaexport.php - - - - message: '#^Variable \$db might not be defined\.$#' - identifier: variable.undefined - count: 2 - path: ../../htdocs/public/agenda/agendaexport.php - - - - message: '#^Variable \$hookmanager might not be defined\.$#' - identifier: variable.undefined - count: 3 - path: ../../htdocs/public/agenda/agendaexport.php - - message: '#^Variable \$langs might not be defined\.$#' identifier: variable.undefined count: 2 path: ../../htdocs/public/agenda/agendaexport.php - - - message: '#^Variable \$user might not be defined\.$#' - identifier: variable.undefined - count: 2 - path: ../../htdocs/public/agenda/agendaexport.php - - message: '#^Negated boolean expression is always true\.$#' identifier: booleanNot.alwaysTrue diff --git a/htdocs/public/agenda/agendaexport.php b/htdocs/public/agenda/agendaexport.php index 9a7af93cbe4ae..1f117a9205835 100644 --- a/htdocs/public/agenda/agendaexport.php +++ b/htdocs/public/agenda/agendaexport.php @@ -91,7 +91,13 @@ function llxFooterVierge() // Load Dolibarr environment require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/comm/action/class/actioncomm.class.php'; - +/** + * @var Conf $conf + * @var DoliDB $db + * @var HookManager $hookmanager + * @var Translate $langs + * @var User $user + */ $object = new ActionComm($db); // Not older than