fix phpstan

This commit is contained in:
Frédéric France
2025-02-03 20:06:32 +01:00
parent 2794f53a10
commit 1dabc6d120
5 changed files with 30 additions and 13 deletions

View File

@@ -14886,12 +14886,6 @@ parameters:
count: 2
path: ../../../htdocs/core/tpl/formlayoutai.tpl.php
-
message: '#^Variable \$langs might not be defined\.$#'
identifier: variable.undefined
count: 1
path: ../../../htdocs/core/tpl/list_print_subtotal.tpl.php
-
message: '#^Variable \$limit might not be defined\.$#'
identifier: variable.undefined

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2024 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by

View File

@@ -1,4 +1,25 @@
<?php
/* Copyright (C) 2025 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*/
/**
* @var Translate $langs
* @var array{nbfield:int,pos?:array<int,int>,val?:array<int,float>} $totalarray
*/
'@phan-var-force array{nbfield:int,pos?:array<int,int>,val?:array<int,float>} $totalarray';

View File

@@ -2,7 +2,7 @@
/* Copyright (C) 2012 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2013 Florian Henry <florian.henry@open-concept.pro>
* Copyright (C) 2014-2020 Laurent Destailleur <eldy@destailleur.fr>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2025 MDW <mdeweerd@users.noreply.github.com>
*
* This program is free software; you can redistribute it and/or modify
@@ -19,12 +19,14 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
/**
* @var CommonObject $object
* @var ?CommonObject $object
* @var Form $form
* @var Translate $langs
* @var User $user
*
* @var int $permissionnote
* @var ?int<0,1> $permissionnote
* @var string $moreparam
* @var ?int $colwidth
* @var string $cssclass
*/
// Protection to avoid direct call of template