Child pages
  • [console] Strict notice about "CompletionCommand::setApplication" method [5.3.0-B1]
Skip to end of metadata
Go to start of metadata

The following strict notice is emitted on each console command usage:

Declaration of Intechnic\InPortal\Core\kernel\Console\Command\CompletionCommand::setApplication()
should be compatible with Symfony\Component\Console\Command\Command::setApplication(Symfony\Component\Console\Application $application = NULL)   
 
Declaration of Intechnic\InPortal\Core\kernel\Console\Command\AbstractCommand::setApplication()
should be compatible with Symfony\Component\Console\Command\Command::setApplication(Symfony\Component\Console\Application $application = NULL) 

Solution

  1. locate all declarations of "setApplication" method where "ConsoleApplication" is being used
  2. change method declaration to use "Symfony\Component\Console\Application" class
  3. at method beginning check that instance of "ConsoleApplication" is being used and throw InvalidArgumentException otherwise

Related Tasks