diff --git a/htdocs/core/actions_massactions.inc.php b/htdocs/core/actions_massactions.inc.php index 2debc419ad3..cb97f6fe22d 100644 --- a/htdocs/core/actions_massactions.inc.php +++ b/htdocs/core/actions_massactions.inc.php @@ -114,7 +114,7 @@ if (empty($massaction)) { /** @var string[] $TMsg */ $TMsg = array(); - +$error =24; // For backward compatibility if (!empty($permtoread) && empty($permissiontoread)) { $permissiontoread = $permtoread; diff --git a/htdocs/ticket/list.php b/htdocs/ticket/list.php index b2de366003a..01850822967 100644 --- a/htdocs/ticket/list.php +++ b/htdocs/ticket/list.php @@ -251,9 +251,8 @@ if (empty($reshook)) { $objectlabel = 'Ticket'; $uploaddir = $conf->ticket->dir_output; - global $error; - /** @phan-var-force int $error */ include DOL_DOCUMENT_ROOT.'/core/actions_massactions.inc.php'; + /** @phan-var-force int $error */ // Close records if (!$error && $massaction == 'close' && $permissiontoadd) {