mirror of
https://github.com/shlinkio/shlink.git
synced 2025-02-20 01:09:56 +03:00
Renamed ConfigCustomizerPluginManager to CongigCustomizerManager
This commit is contained in:
parent
0f0213aa87
commit
5e3770c105
5 changed files with 10 additions and 10 deletions
|
@ -5,7 +5,7 @@ namespace Shlinkio\Shlink\CLI\Command\Install;
|
||||||
|
|
||||||
use Psr\Container\ContainerExceptionInterface;
|
use Psr\Container\ContainerExceptionInterface;
|
||||||
use Psr\Container\NotFoundExceptionInterface;
|
use Psr\Container\NotFoundExceptionInterface;
|
||||||
use Shlinkio\Shlink\CLI\Install\ConfigCustomizerPluginManagerInterface;
|
use Shlinkio\Shlink\CLI\Install\ConfigCustomizerManagerInterface;
|
||||||
use Shlinkio\Shlink\CLI\Install\Plugin;
|
use Shlinkio\Shlink\CLI\Install\Plugin;
|
||||||
use Shlinkio\Shlink\CLI\Model\CustomizableAppConfig;
|
use Shlinkio\Shlink\CLI\Model\CustomizableAppConfig;
|
||||||
use Symfony\Component\Console\Command\Command;
|
use Symfony\Component\Console\Command\Command;
|
||||||
|
@ -40,7 +40,7 @@ class InstallCommand extends Command
|
||||||
*/
|
*/
|
||||||
private $filesystem;
|
private $filesystem;
|
||||||
/**
|
/**
|
||||||
* @var ConfigCustomizerPluginManagerInterface
|
* @var ConfigCustomizerManagerInterface
|
||||||
*/
|
*/
|
||||||
private $configCustomizers;
|
private $configCustomizers;
|
||||||
/**
|
/**
|
||||||
|
@ -52,14 +52,14 @@ class InstallCommand extends Command
|
||||||
* InstallCommand constructor.
|
* InstallCommand constructor.
|
||||||
* @param WriterInterface $configWriter
|
* @param WriterInterface $configWriter
|
||||||
* @param Filesystem $filesystem
|
* @param Filesystem $filesystem
|
||||||
* @param ConfigCustomizerPluginManagerInterface $configCustomizers
|
* @param ConfigCustomizerManagerInterface $configCustomizers
|
||||||
* @param bool $isUpdate
|
* @param bool $isUpdate
|
||||||
* @throws LogicException
|
* @throws LogicException
|
||||||
*/
|
*/
|
||||||
public function __construct(
|
public function __construct(
|
||||||
WriterInterface $configWriter,
|
WriterInterface $configWriter,
|
||||||
Filesystem $filesystem,
|
Filesystem $filesystem,
|
||||||
ConfigCustomizerPluginManagerInterface $configCustomizers,
|
ConfigCustomizerManagerInterface $configCustomizers,
|
||||||
$isUpdate = false
|
$isUpdate = false
|
||||||
) {
|
) {
|
||||||
parent::__construct();
|
parent::__construct();
|
||||||
|
|
|
@ -6,7 +6,7 @@ namespace Shlinkio\Shlink\CLI\Factory;
|
||||||
use Interop\Container\ContainerInterface;
|
use Interop\Container\ContainerInterface;
|
||||||
use Interop\Container\Exception\ContainerException;
|
use Interop\Container\Exception\ContainerException;
|
||||||
use Shlinkio\Shlink\CLI\Command\Install\InstallCommand;
|
use Shlinkio\Shlink\CLI\Command\Install\InstallCommand;
|
||||||
use Shlinkio\Shlink\CLI\Install\ConfigCustomizerPluginManager;
|
use Shlinkio\Shlink\CLI\Install\ConfigCustomizerManager;
|
||||||
use Shlinkio\Shlink\CLI\Install\Plugin;
|
use Shlinkio\Shlink\CLI\Install\Plugin;
|
||||||
use Symfony\Component\Console\Application;
|
use Symfony\Component\Console\Application;
|
||||||
use Symfony\Component\Console\Exception\LogicException;
|
use Symfony\Component\Console\Exception\LogicException;
|
||||||
|
@ -41,7 +41,7 @@ class InstallApplicationFactory implements FactoryInterface
|
||||||
$command = new InstallCommand(
|
$command = new InstallCommand(
|
||||||
new PhpArray(),
|
new PhpArray(),
|
||||||
$container->get(Filesystem::class),
|
$container->get(Filesystem::class),
|
||||||
new ConfigCustomizerPluginManager($container, ['factories' => [
|
new ConfigCustomizerManager($container, ['factories' => [
|
||||||
Plugin\DatabaseConfigCustomizer::class => ConfigAbstractFactory::class,
|
Plugin\DatabaseConfigCustomizer::class => ConfigAbstractFactory::class,
|
||||||
Plugin\UrlShortenerConfigCustomizer::class => InvokableFactory::class,
|
Plugin\UrlShortenerConfigCustomizer::class => InvokableFactory::class,
|
||||||
Plugin\LanguageConfigCustomizer::class => InvokableFactory::class,
|
Plugin\LanguageConfigCustomizer::class => InvokableFactory::class,
|
||||||
|
|
|
@ -6,7 +6,7 @@ namespace Shlinkio\Shlink\CLI\Install;
|
||||||
use Shlinkio\Shlink\CLI\Install\Plugin\ConfigCustomizerInterface;
|
use Shlinkio\Shlink\CLI\Install\Plugin\ConfigCustomizerInterface;
|
||||||
use Zend\ServiceManager\AbstractPluginManager;
|
use Zend\ServiceManager\AbstractPluginManager;
|
||||||
|
|
||||||
class ConfigCustomizerPluginManager extends AbstractPluginManager implements ConfigCustomizerPluginManagerInterface
|
class ConfigCustomizerManager extends AbstractPluginManager implements ConfigCustomizerManagerInterface
|
||||||
{
|
{
|
||||||
protected $instanceOf = ConfigCustomizerInterface::class;
|
protected $instanceOf = ConfigCustomizerInterface::class;
|
||||||
}
|
}
|
|
@ -5,6 +5,6 @@ namespace Shlinkio\Shlink\CLI\Install;
|
||||||
|
|
||||||
use Psr\Container\ContainerInterface;
|
use Psr\Container\ContainerInterface;
|
||||||
|
|
||||||
interface ConfigCustomizerPluginManagerInterface extends ContainerInterface
|
interface ConfigCustomizerManagerInterface extends ContainerInterface
|
||||||
{
|
{
|
||||||
}
|
}
|
|
@ -8,7 +8,7 @@ use Prophecy\Argument;
|
||||||
use Prophecy\Prophecy\MethodProphecy;
|
use Prophecy\Prophecy\MethodProphecy;
|
||||||
use Prophecy\Prophecy\ObjectProphecy;
|
use Prophecy\Prophecy\ObjectProphecy;
|
||||||
use Shlinkio\Shlink\CLI\Command\Install\InstallCommand;
|
use Shlinkio\Shlink\CLI\Command\Install\InstallCommand;
|
||||||
use Shlinkio\Shlink\CLI\Install\ConfigCustomizerPluginManagerInterface;
|
use Shlinkio\Shlink\CLI\Install\ConfigCustomizerManagerInterface;
|
||||||
use Shlinkio\Shlink\CLI\Install\Plugin\ConfigCustomizerInterface;
|
use Shlinkio\Shlink\CLI\Install\Plugin\ConfigCustomizerInterface;
|
||||||
use Symfony\Component\Console\Application;
|
use Symfony\Component\Console\Application;
|
||||||
use Symfony\Component\Console\Helper\ProcessHelper;
|
use Symfony\Component\Console\Helper\ProcessHelper;
|
||||||
|
@ -52,7 +52,7 @@ class InstallCommandTest extends TestCase
|
||||||
$this->configWriter = $this->prophesize(WriterInterface::class);
|
$this->configWriter = $this->prophesize(WriterInterface::class);
|
||||||
|
|
||||||
$configCustomizer = $this->prophesize(ConfigCustomizerInterface::class);
|
$configCustomizer = $this->prophesize(ConfigCustomizerInterface::class);
|
||||||
$configCustomizers = $this->prophesize(ConfigCustomizerPluginManagerInterface::class);
|
$configCustomizers = $this->prophesize(ConfigCustomizerManagerInterface::class);
|
||||||
$configCustomizers->get(Argument::cetera())->willReturn($configCustomizer->reveal());
|
$configCustomizers->get(Argument::cetera())->willReturn($configCustomizer->reveal());
|
||||||
|
|
||||||
$app = new Application();
|
$app = new Application();
|
||||||
|
|
Loading…
Add table
Reference in a new issue