cancel
Showing results for 
Search instead for 
Did you mean: 

trying to install new extensions and I keep getting a PHP Fatal error: Declaration of Laminas....

trying to install new extensions and I keep getting a PHP Fatal error: Declaration of Laminas....

Hi,

 

I am trying to run php bin/magento setup:upgrade but I keep getting this error code

 

PHP Fatal error: Declaration of Laminas\ServiceManager\ServiceLocatorInterface::get($name) must be compatible with Psr\Container\ContainerInterface::get(string $id) in /home/virtual/vps-9dfca1/5/58f94e5df1/public_html/vendor/laminas/laminas-servicemanager/src/ServiceLocatorInterface.php on line 16

 

I have tried to add "psr/container": "1.0.0" in the composer file but this did not work at all Smiley Sad

 

Any Help on this would be greatly appreciated 

1 REPLY 1

Re: trying to install new extensions and I keep getting a PHP Fatal error: Declaration of Laminas..

Hello,
Which version of composer you are using?
I think the composer will downgrade to version 1.0.0 of Psr\Container and if you need to go back to composer 1 use the command:

composer self-update --1

Happy coding Smiley Happy