# Qual: Update Phan baseline and fix type mismatch in conferenceorbooth_list.php
- Updated the Phan baseline to reflect the reduced number of PhanUndeclaredMethod occurrences
- Fixed a type mismatch in conferenceorbooth_list.php by changing the values from integers to strings in the editfieldkey and editfieldval functions
- Update PHP-CS-Fixer configuration to replace deprecated 'visibility_required' rule with 'modifier_keywords'
- Update DolibarrModules class to use const instead of public const for PHP 7.0 compatibility (revert recent change)
* Qual: Add pre-commit hooks for Perl code formatting and linting
- Added perltidy hook to format Perl code
- Added perlcritic hook to lint Perl code
* Qual: Update file opening syntax in build scripts (perltidy)
The changes update the syntax for opening files in several build scripts to use the three-argument form of the `open` function, which is more secure and recommended in modern Perl practices.
* Qual: Improve file handling and add strict/warnings pragmas (perlcritic)
The changes include:
- Adding 'use strict' and 'use warnings' pragmas to enforce better coding practices
- Improving file handling by using lexical filehandles (my $IN, my $SPECFROM, etc.)
- Fixing file opening and closing operations to use proper error handling
- Updating various file operations to use the new lexical filehandles
- Fixing indentation and formatting issues in the code
* Qual: Add strict and warnings pragmas to Perl scripts (perlcritic)
The changes add 'use strict;' and 'use warnings;' pragmas
- dev/build/doxygen/dolibarr-doxygen-build.pl
- dev/build/doxygen/dolibarr-doxygen-filter.pl
- dev/build/doxygen/dolibarr-doxygen-getversion.pl
- dev/build/gource/getavatars.pl
- dev/tools/dolibarr-mysql2pgsql.pl
* Qual: Add Perl no critic pragmas (perlcritic)
- Ignore some perlcritic notices
* Qual: Improve code formatting and readability
Perltidy:
- Indentation and spacing
- Improved variable naming and alignment
- Better code organization and structure
- Enhanced readability of conditional statements and loops
These changes do not alter the functionality of the script but make it more maintainable and easier to understand.
* qual: Exclude virtualmin from perltidy and perlcritic hooks
Exclude the virtualmin directory from both perltidy and perlcritic hooks due to specific reasons mentioned in the comment. This change ensures that these hooks do not process files in the virtualmin directory.
* Qual: Add installation of perltidy and perlcritic for pre-commit workflow
This commit adds the installation of perltidy and perlcritic as part of the pre-commit hooks workflow.
* Fix: Update version detection in dolibarr-doxygen-build.pl
- Add support for detecting version from DOL_MAJOR_VERSION and DOL_MINOR_VERSION constants
- Fix undefined variable issue in version detection
* Fix: Update getavatars.pl to use HTTPS and reverse git log
- Changed the URL from HTTP to HTTPS for Gravatar
- Added `--reverse` flag to git log command to process commits in chronological order (faster)
- Updated error message to indicate .git repository instead of .git directory (+ correct test)
* fix: Correct spelling in error messages and prompts
- Fixed typo in error message for missing environment variables
- Corrected spelling in prompt for module name input
- Improved clarity in comment for target checking
* QUAL update mysql workbench
* NEW add link to mac api rest client for test
* FIX add apple
* FIX Mister D
* FIX Brian is in the kitchen
* FIX modeste
* Revert "FIX modeste"
This reverts commit a268f6265f.
* FIX youhou
* 🐛 Fix PhanTypeMismatchProperty error in invoice creation
The error occurred due to incorrect type handling in the invoice creation process. The changes fix this by properly handling the subtype field as an integer. This ensures type consistency and prevents potential runtime errors.
* FIX: Correct assignment to linkedObjectsIds in card.php
# FIX: Correct assignment to linkedObjectsIds in card.php
Modified the structure of linkedObjectsIds to include the rowid as a key to match the property type.
---------
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
* Qual: Update pre-commit hooks
# Qual: Update pre-commit hook
Updated several pre-commit hooks as long as the new ones are not alpha or beta versions
* Qual: Fix/ignore some shellcheck issues
# Qual: Fix PhanTypeComparisonFromArray in pertype.php and peruser.php
- Update pertype.php and peruser.php to resolve PhanTypeComparisonFromArray notices.
When an array value is set, it's already an array so comparing to '' is
useless and invalid.
- Update baseline.txt to reflect reduced occurrences of phan issues.
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
- Changed reference from 'tva_intra' to 'company_tva_intra' in multiple locations
- Updated baseline.txt to reflect reduced occurrences of PhanTypeArraySuspiciousNull and PhanPluginUndeclaredVariableIsset
* Qual: Fix missing abstract isEnabled for ModeleDon
# Qual: Fix missing abstract isEnabled for ModeleDon
* Qual: Fix donation list fields
# Qual: Fix donation list fields
Fixes PhanTypeMismatchProperty issues in don/list.php by typecasting and
adding d.ref field to query & using it.
* Fix: Fix call to ModeleDon::write_file
- Refactored write_file method in don.class.php to extraneous parameters
- Removed PhanParamTooMany warning from baseline.txt
* Qual: Remove duplicate assignment in list.php
Removed redundant assignment of projectstatic.id.
---------
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
# Fix: Uniform `assign_values` method signatures
`Canvas` is calling `assign_values` with three arguments, so all methods
must have three arguments.
- Modified `actions_adherentcard_common.class.php` and `actions_contactcard_common.class.php` to add object reference parameter
- Updated `actions_adherentcard_default.class.php` and `actions_contactcard_default.class.php` to pass reference parameter to parent class
- Updated Phan baseline to reflect changes in canvas classes
# FIX: Define keyCodeForEnter before first use (takepos)
Move the code to get the keyCodeForEnter from the bottom of the file closer to the top.
This ensure that the variable is defined before first use.
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
* Qual: Fix phan notice with copy of attribute
* Qual: Fix phan notices with cast and updated param definition
* Qual: Fix phan notice with cast
* Qual: Update parameter type hint in utf8_check function
The parameter type hint for the $str parameter in the utf8_check function has been updated to include nullable types (string or int).
* Qual: Update User parameter type to nullable in call_trigger methods
The User parameter in call_trigger methods has been updated to be nullable to accommodate cases where the user object might not be available. This change ensures better flexibility and robustness in the codebase.
* Qual: Update phan baseline
* Qual: phpstan compatible type
* Qual: Add missing type hints for phan
- Add missing type hints for phan
- Fix indentation issues
- Improved consistency in code structure
* Qual: Update field configuration for backward compatibility
Enhanced the field configuration for backward compatibility by adding expected properties to the 'ref' field array.
---------
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
# Qual: Fix misuse of Mo->error
Phan identified that ++ was performed on Mo->error which is a string.
This fixes that by using a local $error variable (as in another
function).
# Qual: Fix phan notices
Some type hints updates + correction to get week from date (action/pertype.php)
+ check that value is not null (pdf_* classes).
# Qual: Update baseline, fix new notice.
Fix small new notice and update baseline with regards to other fixes.
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>