From c2927f1ec645455f8cd44456a7fccc20b51f6376 Mon Sep 17 00:00:00 2001 From: gggeek Date: Tue, 22 Nov 2022 15:24:00 +0000 Subject: [PATCH] nitpicks --- Command/GenerateCommand.php | 6 ------ Command/StatusCommand.php | 2 ++ Core/MigrationService.php | 3 +-- 3 files changed, 3 insertions(+), 8 deletions(-) diff --git a/Command/GenerateCommand.php b/Command/GenerateCommand.php index d14a6897..2acd0d16 100644 --- a/Command/GenerateCommand.php +++ b/Command/GenerateCommand.php @@ -176,8 +176,6 @@ public function execute(InputInterface $input, OutputInterface $output) /// @todo move these 2 params out of here, pass the context as template parameter instead 'lang' => $input->getOption('lang'), 'adminLogin' => $input->getOption('admin-login') - /// @todo should we allow users to specify this ? - //'forceSigchildEnabled' => null ); $date = date('YmdHis'); @@ -384,10 +382,6 @@ protected function migrationContextFromParameters(array $parameters) if (isset($parameters['adminLogin']) && $parameters['adminLogin'] != '') { $context['adminUserLogin'] = $parameters['adminLogin']; } - if (isset($parameters['forceSigchildEnabled']) && $parameters['forceSigchildEnabled'] !== null) - { - $context['forceSigchildEnabled'] = $parameters['forceSigchildEnabled']; - } return $context; } diff --git a/Command/StatusCommand.php b/Command/StatusCommand.php index 2164ae2a..4583907a 100644 --- a/Command/StatusCommand.php +++ b/Command/StatusCommand.php @@ -251,6 +251,8 @@ public function execute(InputInterface $input, OutputInterface $output) ->setHeaders($headers) ->setRows($data); $table->render(); + + return 0; } /** diff --git a/Core/MigrationService.php b/Core/MigrationService.php index 4f4cbf12..35b650cb 100644 --- a/Core/MigrationService.php +++ b/Core/MigrationService.php @@ -294,7 +294,7 @@ public function parseMigrationDefinition(MigrationDefinition $migrationDefinitio * Note: previous API is kept for BC (subclasses reimplementing this method). * @param MigrationDefinition $migrationDefinition * @param array $migrationContext Supported array keys are: adminUserLogin, defaultLanguageCode, - * forcedReferences, forceExecution, forceSigchildEnabled, userContentType, userGroupContentType, + * forcedReferences, forceExecution, userContentType, userGroupContentType, * useTransaction. * Bool usage is deprecated. It was: when set to false, no repo transaction will be used to wrap the migration * @param string $defaultLanguageCode Deprecated - use $migrationContext['defaultLanguageCode'] @@ -303,7 +303,6 @@ public function parseMigrationDefinition(MigrationDefinition $migrationDefinitio * @param bool|null $forceSigchildEnabled Deprecated * @throws \Exception * - * @todo add support for setting in $migrationContext a userContentType, userGroupContentType ? * @todo treating a null and false $adminLogin values differently is prone to hard-to-track errors. * Shall we use instead -1 to indicate the desire to not-login-as-admin-user-at-all ? */