@@ -6,7 +6,6 @@ |
||
| 6 | 6 | use PDOException; |
| 7 | 7 | use RuntimeException; |
| 8 | 8 | use Symfony\Component\Console\Helper\Helper as AbstractHelper; |
| 9 | -use N98\Magento\Application; |
|
| 10 | 9 | use Symfony\Component\Console\Output\NullOutput; |
| 11 | 10 | use Symfony\Component\Console\Output\OutputInterface; |
| 12 | 11 | |
@@ -298,7 +298,7 @@ discard block |
||
| 298 | 298 | $definitions, |
| 299 | 299 | $resolved |
| 300 | 300 | ); |
| 301 | - $resolvedList = array_merge($resolvedList, $tables); |
|
| 301 | + $resolvedList = array_merge($resolvedList, $tables); |
|
| 302 | 302 | } |
| 303 | 303 | continue; |
| 304 | 304 | } |
@@ -357,7 +357,7 @@ discard block |
||
| 357 | 357 | return $result; |
| 358 | 358 | } |
| 359 | 359 | |
| 360 | - return array_map(function ($tableName) use ($prefix) { |
|
| 360 | + return array_map(function($tableName) use ($prefix) { |
|
| 361 | 361 | return str_replace($prefix, '', $tableName); |
| 362 | 362 | }, $result); |
| 363 | 363 | } |
@@ -3,7 +3,6 @@ |
||
| 3 | 3 | namespace N98\Util\Console\Helper; |
| 4 | 4 | |
| 5 | 5 | use N98\Magento\Application; |
| 6 | -use N98\Util\BinaryString; |
|
| 7 | 6 | use RuntimeException; |
| 8 | 7 | use Symfony\Component\Console\Helper\Helper as AbstractHelper; |
| 9 | 8 | use Symfony\Component\Console\Input\ArgvInput; |
@@ -9,7 +9,6 @@ |
||
| 9 | 9 | use Symfony\Component\Console\Helper\Helper as AbstractHelper; |
| 10 | 10 | use Symfony\Component\Console\Output\OutputInterface; |
| 11 | 11 | use Symfony\Component\Console\Input\InputInterface; |
| 12 | -use Symfony\Component\Console\Output\Output; |
|
| 13 | 12 | use Symfony\Component\Translation\Translator; |
| 14 | 13 | use Symfony\Component\Validator\Constraint; |
| 15 | 14 | use Symfony\Component\Validator\Validator; |
@@ -83,7 +83,7 @@ discard block |
||
| 83 | 83 | $storeId = $this->getHelperSet()->get('dialog')->askAndValidate( |
| 84 | 84 | $output, |
| 85 | 85 | $question, |
| 86 | - function ($typeInput) use ($stores) { |
|
| 86 | + function($typeInput) use ($stores) { |
|
| 87 | 87 | if (!isset($stores[$typeInput - 1])) { |
| 88 | 88 | throw new InvalidArgumentException('Invalid store'); |
| 89 | 89 | } |
@@ -143,7 +143,7 @@ discard block |
||
| 143 | 143 | $websiteId = $this->getHelperSet()->get('dialog')->askAndValidate( |
| 144 | 144 | $output, |
| 145 | 145 | $question, |
| 146 | - function ($typeInput) use ($websites) { |
|
| 146 | + function($typeInput) use ($websites) { |
|
| 147 | 147 | if (!isset($websites[$typeInput - 1])) { |
| 148 | 148 | throw new InvalidArgumentException('Invalid store'); |
| 149 | 149 | } |
@@ -238,7 +238,7 @@ discard block |
||
| 238 | 238 | $value = $this->getHelperSet()->get('dialog')->askAndValidate( |
| 239 | 239 | $output, |
| 240 | 240 | $question, |
| 241 | - function ($typeInput) use ($validator, $constraints, $name) { |
|
| 241 | + function($typeInput) use ($validator, $constraints, $name) { |
|
| 242 | 242 | $errors = $validator->validateValue(array($name => $typeInput), $constraints); |
| 243 | 243 | if (count($errors) > 0) { |
| 244 | 244 | throw new InvalidArgumentException($errors[0]->getMessage()); |
@@ -2,8 +2,6 @@ |
||
| 2 | 2 | |
| 3 | 3 | namespace N98\Magento\Command\Database\Maintain; |
| 4 | 4 | |
| 5 | -use Symfony\Component\Console\Output\NullOutput; |
|
| 6 | -use Symfony\Component\Console\Tester\ApplicationTester; |
|
| 7 | 5 | use Symfony\Component\Console\Tester\CommandTester; |
| 8 | 6 | use N98\Magento\Command\PHPUnit\TestCase; |
| 9 | 7 | |
@@ -2,7 +2,6 @@ |
||
| 2 | 2 | |
| 3 | 3 | namespace N98\Util\Console\Helper; |
| 4 | 4 | |
| 5 | -use Symfony\Component\Console\Tester\CommandTester; |
|
| 6 | 5 | use N98\Magento\Command\PHPUnit\TestCase; |
| 7 | 6 | |
| 8 | 7 | |
@@ -73,7 +73,7 @@ |
||
| 73 | 73 | foreach ($cacheTypes as $cacheType) { |
| 74 | 74 | |
| 75 | 75 | // If 'enabled' option is set, filter those who match |
| 76 | - if (! is_null($input->getOption('enabled')) && $input->getOption('enabled') != $cacheType->getStatus()) { |
|
| 76 | + if (!is_null($input->getOption('enabled')) && $input->getOption('enabled') != $cacheType->getStatus()) { |
|
| 77 | 77 | unset($cacheTypes[$cacheType->getId()]); |
| 78 | 78 | continue; |
| 79 | 79 | } |
@@ -187,7 +187,7 @@ |
||
| 187 | 187 | */ |
| 188 | 188 | protected function formatVariables(array $vars) |
| 189 | 189 | { |
| 190 | - $rounding = (int)$this->_input->getOption('rounding'); |
|
| 190 | + $rounding = (int) $this->_input->getOption('rounding'); |
|
| 191 | 191 | if ($rounding > -1) { |
| 192 | 192 | foreach ($vars as $k => &$v) { |
| 193 | 193 | if (true === $this->allowRounding($k)) { |
@@ -72,7 +72,7 @@ |
||
| 72 | 72 | 'max_write_lock_count' => 1, |
| 73 | 73 | 'slave_max_allowed_packet' => 1, |
| 74 | 74 | ); |
| 75 | - $isSize = false !== strpos($name, '_size'); |
|
| 75 | + $isSize = false !== strpos($name, '_size'); |
|
| 76 | 76 | |
| 77 | 77 | return $isSize || isset($toHuman[$name]); |
| 78 | 78 | } |
@@ -31,7 +31,7 @@ |
||
| 31 | 31 | $this->getCommand()->getHelper('twig')->render($template, $this->config->getArray('twigVars')) |
| 32 | 32 | ); |
| 33 | 33 | |
| 34 | - $this->output->writeln('<info>Created file: <comment>' . $outFile .'<comment></info>'); |
|
| 34 | + $this->output->writeln('<info>Created file: <comment>' . $outFile . '<comment></info>'); |
|
| 35 | 35 | } |
| 36 | 36 | |
| 37 | 37 | } |