• Resolved dbase66

    (@dbase66)


    Method ReflectionParameter::getClass() is deprecated+

    1. wp-content/plugins/custom-php-settings/src/Vendor/php-di/php-di/src/DI/Invoker/FactoryParameterResolver.php:44
Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author cyclonecode

    (@cyclonecode)

    This is only a warning, but I will have a look on it.

    Plugin Author cyclonecode

    (@cyclonecode)

    The warning comes from the PHP-DI package and is kind of hard to resolve without switching to some other DI container since I would like to support PHP 5.6+ which means I cannot bump the PHP-DI package to any later version. I would really like to drop support for PHP 5.6, but thinking that there might be many users that still sits on this very outdated version.

    I will think some more =)

    Thread Starter dbase66

    (@dbase66)

    Is it possible, to maintain the third-party-package?

    Plugin Author cyclonecode

    (@cyclonecode)

    I actually already do this. I think I could refactor the code in the php-di package and use https://www.php.net/manual/en/reflectionparameter.gettype.php instead which would solve this problem for PHP 8+.

    Thread Starter dbase66

    (@dbase66)

    getType() instead of getClass() ???

    Plugin Author cyclonecode

    (@cyclonecode)

    This issue should be resolved in the latest version 2.1.0. I still think I actually will drop support for PHP 5.6 and only support 7.0+ which would make things much easier to maintain.

    The updated code looks like this:

    $parameterClass = @$parameter->getType();
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘PHP 8.2 Problem’ is closed to new replies.