Jump to content

Edit History

Andrei H

Andrei H

Hello,

PrestaShop 8 does not support PHP 8.2 yet, as highlighted in here: https://devdocs.prestashop-project.org/8/basics/installation/system-requirements/#php-compatibility-chart

Unless you want to manually fix these warnings, it is recommended to downgrade to PHP 8.1

These warnings are thrown because in some classes, some methods are setting properties without having these properties defined in the class.

Here is an example:

class SomeClass
{
    public function __construct(string $str)
    {
        $this->str = $str;
    }
}

This case will throw the warning, because the property str is not defined in the class. In order to fix it, you just need to define that property:

class SomeClass
{
    public string $str;
    
    public function __construct(string $str)
    {
        $this->str = $str;
    }
}

 

Andrei H

Andrei H

Hello,

PrestaShop 8 does not support PHP 8.2 yet, as highlighted in here: https://devdocs.prestashop-project.org/8/basics/installation/system-requirements/#php-compatibility-chart

Unless you want to manually fix these warnings, it is recommended to downgrade to PHP 8.1

These warnings are thrown because in some classes, some methods are setting properties without having these properties defined in the class.

Here is an example:

class SomeClass
{
    public function __construct(string $str) {
        $this->str = $str;
    }
}

This case will throw the warning, because the property str is not defined in the class. In order to fix it, you just need to define that property:

class SomeClass
{
    public $str;
    
    public function __construct(string $str) {
        $this->str = $str;
    }
}

 

×
×
  • Create New...