mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
clean phpstan baseline (#31921)
* clean phpstan baseline * clean phpstan baseline * clean phpstan baseline
This commit is contained in:
parent
ec6f591199
commit
cb7d4d1ad5
|
|
@ -11106,12 +11106,6 @@ parameters:
|
|||
count: 4
|
||||
path: ../../htdocs/core/class/ctyperesource.class.php
|
||||
|
||||
-
|
||||
message: '#^Property CUnits\:\:\$scale \(string\) in isset\(\) is not nullable\.$#'
|
||||
identifier: isset.property
|
||||
count: 4
|
||||
path: ../../htdocs/core/class/cunits.class.php
|
||||
|
||||
-
|
||||
message: '#^Property CUnits\:\:\$short_label \(string\) in isset\(\) is not nullable\.$#'
|
||||
identifier: isset.property
|
||||
|
|
@ -22308,12 +22302,6 @@ parameters:
|
|||
count: 1
|
||||
path: ../../htdocs/fourn/commande/card.php
|
||||
|
||||
-
|
||||
message: '#^Variable \$text might not be defined\.$#'
|
||||
identifier: variable.undefined
|
||||
count: 2
|
||||
path: ../../htdocs/fourn/commande/card.php
|
||||
|
||||
-
|
||||
message: '#^If condition is always false\.$#'
|
||||
identifier: if.alwaysFalse
|
||||
|
|
@ -27252,12 +27240,6 @@ parameters:
|
|||
count: 1
|
||||
path: ../../htdocs/partnership/partnership_card.php
|
||||
|
||||
-
|
||||
message: '#^Variable \$upload_dir might not be defined\.$#'
|
||||
identifier: variable.undefined
|
||||
count: 1
|
||||
path: ../../htdocs/partnership/partnership_document.php
|
||||
|
||||
-
|
||||
message: '#^Negated boolean expression is always true\.$#'
|
||||
identifier: booleanNot.alwaysTrue
|
||||
|
|
@ -30432,18 +30414,6 @@ parameters:
|
|||
count: 1
|
||||
path: ../../htdocs/projet/tasks/comment.php
|
||||
|
||||
-
|
||||
message: '#^Variable \$mode might not be defined\.$#'
|
||||
identifier: variable.undefined
|
||||
count: 1
|
||||
path: ../../htdocs/projet/tasks/comment.php
|
||||
|
||||
-
|
||||
message: '#^Variable \$socid might not be defined\.$#'
|
||||
identifier: variable.undefined
|
||||
count: 1
|
||||
path: ../../htdocs/projet/tasks/comment.php
|
||||
|
||||
-
|
||||
message: '#^Call to function method_exists\(\) with Project and ''fetchComments'' will always evaluate to true\.$#'
|
||||
identifier: function.alreadyNarrowedType
|
||||
|
|
|
|||
|
|
@ -80,9 +80,7 @@ $extrafields->fetch_name_optionals_label($object->table_element);
|
|||
// Load object
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be 'include', not 'include_once'. Include fetch and fetch_thirdparty but not fetch_optionals
|
||||
|
||||
if ($id > 0 || !empty($ref)) {
|
||||
$upload_dir = $conf->partnership->multidir_output[$object->entity ? $object->entity : $conf->entity]."/partnership/".get_exdir(0, 0, 0, 1, $object);
|
||||
}
|
||||
$upload_dir = $conf->partnership->multidir_output[$object->entity ?: $conf->entity]."/partnership/".get_exdir(0, 0, 0, 1, $object);
|
||||
|
||||
$permissiontoread = $user->hasRight('partnership', 'read');
|
||||
$permissiontoadd = $user->hasRight('partnership', 'write'); // Used by the include of actions_addupdatedelete.inc.php
|
||||
|
|
|
|||
|
|
@ -56,6 +56,7 @@ $confirm = GETPOST('confirm', 'alpha');
|
|||
$withproject = GETPOSTINT('withproject');
|
||||
$project_ref = GETPOST('project_ref', 'alpha');
|
||||
$planned_workload = ((GETPOSTINT('planned_workloadhour') != '' || GETPOSTINT('planned_workloadmin') != '') ? (GETPOSTINT('planned_workloadhour') > 0 ? GETPOSTINT('planned_workloadhour') * 3600 : 0) + (GETPOSTINT('planned_workloadmin') > 0 ? GETPOSTINT('planned_workloadmin') * 60 : 0) : '');
|
||||
$mode = GETPOST('mode', 'alpha');
|
||||
|
||||
// Initialize a technical object to manage hooks of page. Note that conf->hooks_modules contains an array of hook context
|
||||
$hookmanager->initHooks(array('projecttaskcommentcard', 'globalcard'));
|
||||
|
|
@ -70,6 +71,8 @@ $extrafields->fetch_name_optionals_label($object->table_element);
|
|||
// include comment actions
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_comments.inc.php';
|
||||
|
||||
// Security check
|
||||
$socid = 0;
|
||||
// Retrieve First Task ID of Project if withprojet is on to allow project prev next to work
|
||||
if (!empty($project_ref) && !empty($withproject)) {
|
||||
if ($projectstatic->fetch(0, $project_ref) > 0) {
|
||||
|
|
@ -87,9 +90,6 @@ if ($id > 0 || $ref) {
|
|||
$object->fetch($id, $ref);
|
||||
}
|
||||
|
||||
// Security check
|
||||
$socid = 0;
|
||||
|
||||
restrictedArea($user, 'projet', $object->fk_project, 'projet&project');
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user