Fix warnings for PHP 8.4+ (#6781)

This commit is contained in:
Alexandre Alapetite
2024-09-06 10:41:11 +02:00
committed by GitHub
parent 7095f1d3b0
commit 0ea13253af
3 changed files with 7 additions and 6 deletions

View File

@@ -13,7 +13,8 @@ See also [the FreshRSS releases](https://github.com/FreshRSS/FreshRSS/releases).
* Use curl to fetch extensions list (allows e.g. IPv6) [#6767](https://github.com/FreshRSS/FreshRSS/pull/6767)
* Compatibility
* Require PHP 8.1+ (drop PHP 7.4) [#6711](https://github.com/FreshRSS/FreshRSS/pull/6711)
* Improved support of PHP 8.4+ [#6618](https://github.com/FreshRSS/FreshRSS/pull/6618), [PhpGt/CssXPath#227](https://github.com/PhpGt/CssXPath/pull/227)
* Improved support of PHP 8.4+ [#6618](https://github.com/FreshRSS/FreshRSS/pull/6618), [PhpGt/CssXPath#227](https://github.com/PhpGt/CssXPath/pull/227),
[#6781](https://github.com/FreshRSS/FreshRSS/pull/6781)
* Require PostgreSQL 10+ (drop PostgreSQL 9.5) [#6705](https://github.com/FreshRSS/FreshRSS/pull/6705)
* Require MariaDB 10.0.5+ (drop MariaDB 5.5) [#6706](https://github.com/FreshRSS/FreshRSS/pull/6706)
* Requiring MySQL 8+ (drop MySQL 5.5.3) [#6706](https://github.com/FreshRSS/FreshRSS/pull/6706)

View File

@@ -72,7 +72,7 @@ lint-fix: vendor/bin/phpcbf ## Fix the errors detected by the linter
bin/composer:
mkdir -p bin/
wget 'https://raw.githubusercontent.com/composer/getcomposer.org/163a517dbb7eba0eb25633061c76e648392c6738/web/installer' -O - -q | php -- --quiet --install-dir='./bin/' --filename='composer'
wget 'https://raw.githubusercontent.com/composer/getcomposer.org/1a26c0dcb361332cb504e4861ed0f758281575aa/web/installer' -O - -q | php -- --quiet --install-dir='./bin/' --filename='composer'
vendor/bin/phpunit: bin/composer
bin/composer install --prefer-dist --no-progress

View File

@@ -29,8 +29,8 @@ class Minz_Configuration {
* @param Minz_ConfigurationSetterInterface $configuration_setter an optional helper to set values in configuration
* @throws Minz_FileNotExistException
*/
public static function register(string $namespace, string $config_filename, string $default_filename = null,
Minz_ConfigurationSetterInterface $configuration_setter = null): void {
public static function register(string $namespace, string $config_filename, ?string $default_filename = null,
?Minz_ConfigurationSetterInterface $configuration_setter = null): void {
self::$config_list[$namespace] = new static(
$namespace, $config_filename, $default_filename, $configuration_setter
);
@@ -105,8 +105,8 @@ class Minz_Configuration {
* @param Minz_ConfigurationSetterInterface $configuration_setter an optional helper to set values in configuration
* @throws Minz_FileNotExistException
*/
final private function __construct(string $namespace, string $config_filename, string $default_filename = null,
Minz_ConfigurationSetterInterface $configuration_setter = null) {
final private function __construct(string $namespace, string $config_filename, ?string $default_filename = null,
?Minz_ConfigurationSetterInterface $configuration_setter = null) {
$this->namespace = $namespace;
$this->config_filename = $config_filename;
$this->default_filename = $default_filename;