Commit graph

501 commits

Author SHA1 Message Date
github-actions[bot]
cac0e048ca
PHPStan > Update baseline (#39571)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-08-17 21:29:05 +02:00
Frédéric FRANCE
840538d702
FIX: Resolve possibly-undefined-variable cases flagged by PHPStan (#39523)
* FIX: Resolve possibly-undefined-variable cases flagged by PHPStan

Fixes several cases of the variable.undefined PHPStan rule instead of
just excluding them via the baseline: a wrong variable used to build a
delete link (dir_add_card.php), an uninitialized $result across a
try/catch (CMailFile), missing GETPOST reads ($mode, $fk_project/$date
reset via unset() creating cross-branch ambiguity), a missing $r
contract check (commonfieldsinimport.inc.php), missing @var/global
annotations for $conf/$langs/$bc, dead extrafields-display code
guarded by the wrong condition (expedition/card.php), and an
undefined $soc passed to formAddObjectLine() where objects have no
buyer thirdparty (replaced with null). Corresponding entries removed
from dev/build/phpstan/phpstan-baseline.neon.

* FIX: Resolve more possibly-undefined-variable cases flagged by PHPStan

Second batch of variable.undefined fixes removed from the baseline:
- Complex conditional flows PHPStan can't prove exhaustive (Stripe key
  selection in commoninvoice.class.php, a situation-invoice loop var in
  pdf_sponge.modules.php, a product loop var in stock/movement_list.php)
  fixed by adding a definite initialization before the ambiguous branch.
- A commented-out $linkback assignment restored in
  expensereport/payment/info.php.
- Missing GETPOST reads added (holiday/list.php update-date filters,
  product/stock/info.php $action/$socid, projet/comment.php $mode).
- A dead-code $mesg call to dol_htmloutput_mesg() removed from
  admin_hrm.php (messages are already shown via setEventMessages()).
- Redundant isset() checks removed in product/reassort.php and
  reassortlot.php where $type is unconditionally set earlier in the
  same file, so the isset()-false branch was unreachable dead code.
- $user documented as always available in public/bookcal/index.php
  (NOREQUIREUSER is not defined on that page).
- A genuinely missing $tmpcode initialization fixed in
  attendee_new.php, suggestbooth.php and suggestconference.php: when
  an existing thirdparty is reused (or SOCIETE_CODECLIENT_ADDON has no
  auto-numbering), $tmpcode was never set before being assigned to
  code_client/code_fournisseur.

* add phan fix

* add phan fix

* fix

* fix

* fix
2026-08-15 18:33:12 +02:00
Laurent Destailleur
b4db290594 Merge branch '24.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-08-14 02:37:17 +02:00
Laurent Destailleur
368f3d74b7 Debug v24 2026-08-13 19:21:32 +02:00
github-actions[bot]
db45772fd9
PHPStan > Update baseline (#39408)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-08-06 17:50:40 +02:00
Laurent Destailleur
7011475563 Prepare release 2026-07-30 11:23:07 +02:00
Laurent Destailleur
cbcd1cc14f Fix warning 2026-07-29 18:46:50 +02:00
Laurent Destailleur
8df0c160c3 Doc 2026-07-24 10:01:56 +02:00
github-actions[bot]
f495b92d1f
PHPStan > Update baseline (#39193)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-07-19 16:17:31 +02:00
Laurent Destailleur
0d414fcb51 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-07-18 16:17:03 +02:00
Laurent Destailleur
1f779ba604 ci 2026-07-16 00:32:50 +02:00
Laurent Destailleur
d99840c759 ci 2026-07-16 00:20:39 +02:00
Laurent Destailleur
17b3dd2c04 CI 2026-07-16 00:14:45 +02:00
github-actions[bot]
e8227696b4
PHPStan > Update baseline (#39174)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-07-15 00:39:16 +02:00
github-actions[bot]
324179f373
PHPStan > Update baseline (#38974)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-06-23 20:13:28 +02:00
Laurent Destailleur
4fe3f862d8 Fix list of files 2026-06-20 02:05:37 +02:00
Laurent Destailleur
aa5cd96de6 Update list of files in unalterable list. 2026-06-19 23:40:38 +02:00
github-actions[bot]
6d21d3df56
PHPStan > Update baseline (#38823)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-06-15 14:57:55 +02:00
github-actions[bot]
277a38eff7
PHPStan > Update baseline (#38780)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-06-14 01:06:22 +02:00
github-actions[bot]
65233b182f
PHPStan > Update baseline (#38465)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-06-10 19:52:57 +02:00
Laurent Destailleur
73f2cfb9b4 Log 2026-06-09 02:15:06 +02:00
Laurent Destailleur
b8f9d4ab78 Fix tool for generation of signatures 2026-06-01 22:55:42 +02:00
Laurent Destailleur
593f855244 Fix script to generate file 2026-06-01 20:10:17 +02:00
Laurent Destailleur
754f991798 Debug v24 2026-05-26 17:12:48 +02:00
Laurent Destailleur
16956c092a Debug 2026-05-26 16:58:26 +02:00
github-actions[bot]
ade06212fe
PHPStan > Update baseline (#38436)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-05-26 05:17:58 +02:00
Laurent Destailleur
b045de9e9b Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-05-25 01:09:03 +02:00
Laurent Destailleur
f32a4884e8 Merge branch '22.0' of git@github.com:Dolibarr/dolibarr.git into 23.0 2026-05-25 01:07:38 +02:00
Laurent Destailleur
bd97fbd653 Fix debian package 2026-05-25 01:01:08 +02:00
MDW
b34c5530d9
Qual: Fix PHPStan notices (#38388)
* Qual: Fix ftp related typing for PHPStan

* Qual: Fix multiple PHPStan notices

* Qual: Update PHPStan baseline
2026-05-22 11:22:11 +02:00
MDW
bc2a6c68f0
Qual: Fix PHPStan notice about menumanager (#38360)
* Qual: Fix PHPStan notice about menumanager

# Qual: Fix PHPStan notice about menumanager

Declare type for MenuManager $menumanager typically defined in menu.inc.php

* Qual: Update PHPStan baseline

# Qual: Update PHPStan baseline

Removed the warning for the undefined variable $menumanager in style.css.php.
2026-05-22 10:39:43 +02:00
MDW
1a66f03134
Qual: Update dol_ftp_connect return type for PHPStan (#38362)
# Qual: Update dol_ftp_connect return type for PHPStan

Fixes Phan notices in ftp/index.php

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-05-22 10:26:58 +02:00
MDW
bd1abf66e4
qual: Update return type annotations in Projects::getRoles() (#38338)
The return type annotations for the method Projects::getRoles() have been updated from array<object> to list<string> to better reflect the actual return type. This change was also reflected in the phpstan-baseline.neon file to maintain consistency.
2026-05-21 21:54:31 +02:00
MDW
0a64b8b47d
Qual: Update parameter type, fixes PHPStan, Phan (#38339)
# Qual: Update parameter type, fixes PHPStan, Phan

Updates the _cleanObjectDatasRate method parameter types.
2026-05-21 21:53:20 +02:00
MDW
24bba6caa9
Qual: Fix PHPStan for ldap, pgsql, odtphp (#38246)
# Qual: Fix PHPStan for ldap, pgsql, odtphp

- Adjust typing in ldap and pgsql class to fix PHPStan notices;
- Exclude all files for odtphp from analysis (external lib);
- Update PHPStan baseline.
2026-05-18 03:01:50 +02:00
Laurent Destailleur
d84479e30f Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-05-17 18:20:43 +02:00
Laurent Destailleur
57d0be7dc9 Fix packaging 23.0.3 2026-05-17 18:19:40 +02:00
Laurent Destailleur
a7af2b7a69 Fix packaging 2026-05-17 18:10:33 +02:00
Laurent Destailleur
8172b31c56 Debug makepack scripts 2026-05-17 16:31:00 +02:00
Laurent Destailleur
8ecf2f9700 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-05-17 15:38:08 +02:00
Laurent Destailleur
34ab5bcc33 Prepare v23 2026-05-17 15:28:20 +02:00
Laurent Destailleur
461e65b069 Disable db check 2026-05-11 22:16:54 +02:00
MDW
63833674bb
Qual: Fix PHPStan notices (#38039)
* Qual: Fix PHPStan notices

# Qual: Fix PHPStan notices

Fix multiple PHPStan notices, mostly possibly undefined variable

* Qual: Fix Phan notices

* Qual: Fix Phan notice, $id declared before include

* Fix array initialisations

* Qual: Update phpstan baseline

* Qual: Fix Phan notices

* Qual: Update phan baseline
2026-05-11 20:39:31 +02:00
Laurent Destailleur
ddfe11b1ac ci 2026-05-11 01:25:10 +02:00
Laurent Destailleur
b592e57943 Prepare 24.0.0 2026-05-11 01:15:23 +02:00
MDW
2e07d07aae
Qual: Update phpstan baseline (#38152) 2026-05-10 22:42:14 +02:00
MDW
8e2868c291
Qual: Fix PHPStan (array definition) (#38071)
* Qual: Fix PHPStan (array definition)

# Qual: Fix PHPStan (array definition)

More complete array definition for $TNetNeeds argument

* Qual: Update PHPStan baseline

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-05-04 17:36:05 +02:00
Laurent Destailleur
166cef8bc2 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-04-26 20:36:20 +02:00
Laurent Destailleur
383a7a2ef4 Fix remove the install.forced.php 2026-04-26 19:02:54 +02:00
github-actions[bot]
6b75da47f9
PHPStan > Update baseline (#37975)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-04-23 14:13:08 +02:00