Completed
Pull Request — master (#20)
by
unknown
01:34
created
src/Module/Command/ModuleCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@
 block discarded – undo
44 44
         if (in_array($this->getName(), ['module:register', 'module:unregister'])
45 45
             && $module->isThirdParty() && !$input->getOption('confirm-thirdparty')
46 46
         ) {
47
-            $output->writeln($module->isThirdParty() . ' is not a kernel module. Correct operation cannot be guaranteed for third-party modules!');
47
+            $output->writeln($module->isThirdParty().' is not a kernel module. Correct operation cannot be guaranteed for third-party modules!');
48 48
         }
49 49
     }
50 50
 
Please login to merge, or discard this patch.
src/Module/Exception/ModuleException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,6 +17,6 @@
 block discarded – undo
17 17
      */
18 18
     public function __construct($message, $moduleName, \Exception $previous = null)
19 19
     {
20
-        parent::__construct("[$moduleName] " . $message, 0, $previous);
20
+        parent::__construct("[$moduleName] ".$message, 0, $previous);
21 21
     }
22 22
 }
23 23
\ No newline at end of file
Please login to merge, or discard this patch.
src/Cache/Command/ClearCommand.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -56,12 +56,12 @@
 block discarded – undo
56 56
 
57 57
         if ($dir) {
58 58
             $cache->cleanDir($dir);
59
-            $output->writeln('<info>Bitrix cache by "/' . BX_ROOT . '/cache/' . $dir . '" dir was deleted</info>');
59
+            $output->writeln('<info>Bitrix cache by "/'.BX_ROOT.'/cache/'.$dir.'" dir was deleted</info>');
60 60
         }
61 61
 
62 62
         if ($tag) {
63 63
             Application::getInstance()->getTaggedCache()->clearByTag($tag);
64
-            $output->writeln('<info>Bitrix cache by tag "' . $tag . '" was deleted</info>');
64
+            $output->writeln('<info>Bitrix cache by tag "'.$tag.'" was deleted</info>');
65 65
         }
66 66
     }
67 67
 }
68 68
\ No newline at end of file
Please login to merge, or discard this patch.
src/Iblock/Command/ImportCommand.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -95,9 +95,9 @@
 block discarded – undo
95 95
             ->setType($this->type)
96 96
             ->setSites($this->sites)
97 97
             ->setActionSection($input->getOption('sections'))
98
-            ->setActionElement($input->getOption('elements'));;
98
+            ->setActionElement($input->getOption('elements')); ;
99 99
 
100
-        foreach (glob(implode(DIRECTORY_SEPARATOR . '*', [$this->dir, $this->extension])) as $file) {
100
+        foreach (glob(implode(DIRECTORY_SEPARATOR.'*', [$this->dir, $this->extension])) as $file) {
101 101
 
102 102
             try {
103 103
                 $importer
Please login to merge, or discard this patch.
Unused Use Statements   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -2,14 +2,14 @@
 block discarded – undo
2 2
 
3 3
 namespace Notamedia\ConsoleJedi\Iblock\Command;
4 4
 
5
-use Notamedia\ConsoleJedi\Application\Command\BitrixCommand;
6
-use Notamedia\ConsoleJedi\Iblock\Exception\IblockException;
7
-use Notamedia\ConsoleJedi\Iblock\Importer;
8
-use Symfony\Component\Console\Input\InputArgument;
9
-use Symfony\Component\Console\Input\InputInterface;
10
-use Symfony\Component\Console\Input\InputOption;
11
-use Symfony\Component\Console\Output\OutputInterface;
12
-use Symfony\Component\Console\Helper\FormatterHelper;
5
+use Notamedia\ConsoleJedi\Application\Command\BitrixCommand;
6
+use Notamedia\ConsoleJedi\Iblock\Exception\IblockException;
7
+use Notamedia\ConsoleJedi\Iblock\Importer;
8
+use Symfony\Component\Console\Input\InputArgument;
9
+use Symfony\Component\Console\Input\InputInterface;
10
+use Symfony\Component\Console\Input\InputOption;
11
+use Symfony\Component\Console\Output\OutputInterface;
12
+use Symfony\Component\Console\Helper\FormatterHelper;
13 13
 use Bitrix\Main\Loader;
14 14
 
15 15
 /**
Please login to merge, or discard this patch.
src/Iblock/Command/ExportCommand.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -96,7 +96,7 @@
 block discarded – undo
96 96
 
97 97
             try {
98 98
                 $xml_id = \CIBlockCMLExport::GetIBlockXML_ID($iblock['ID']);
99
-                $path = implode(DIRECTORY_SEPARATOR, [$this->dir, $xml_id]) . $this->extension;
99
+                $path = implode(DIRECTORY_SEPARATOR, [$this->dir, $xml_id]).$this->extension;
100 100
 
101 101
                 $exporter
102 102
                     ->setPath($path)
Please login to merge, or discard this patch.
Unused Use Statements   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -2,14 +2,14 @@
 block discarded – undo
2 2
 
3 3
 namespace Notamedia\ConsoleJedi\Iblock\Command;
4 4
 
5
-use Notamedia\ConsoleJedi\Application\Command\BitrixCommand;
6
-use Notamedia\ConsoleJedi\Iblock\Exception\IblockException;
7
-use Notamedia\ConsoleJedi\Iblock\Exporter;
8
-use Symfony\Component\Console\Input\InputArgument;
9
-use Symfony\Component\Console\Input\InputInterface;
10
-use Symfony\Component\Console\Input\InputOption;
11
-use Symfony\Component\Console\Output\OutputInterface;
12
-use Symfony\Component\Console\Helper\FormatterHelper;
5
+use Notamedia\ConsoleJedi\Application\Command\BitrixCommand;
6
+use Notamedia\ConsoleJedi\Iblock\Exception\IblockException;
7
+use Notamedia\ConsoleJedi\Iblock\Exporter;
8
+use Symfony\Component\Console\Input\InputArgument;
9
+use Symfony\Component\Console\Input\InputInterface;
10
+use Symfony\Component\Console\Input\InputOption;
11
+use Symfony\Component\Console\Output\OutputInterface;
12
+use Symfony\Component\Console\Helper\FormatterHelper;
13 13
 use Bitrix\Main\Loader;
14 14
 
15 15
 /**
Please login to merge, or discard this patch.
src/Iblock/Importer.php 2 patches
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -122,8 +122,9 @@
 block discarded – undo
122 122
     {
123 123
         $handle = fopen($this->config['path'], "r");
124 124
 
125
-        if (!$handle)
126
-            throw new ImportException('Unable to open file, or file not exist');
125
+        if (!$handle) {
126
+                    throw new ImportException('Unable to open file, or file not exist');
127
+        }
127 128
 
128 129
         if (!$this->import->CheckIfFileIsCML($this->config['path'])) {
129 130
             throw new ImportException('File is not valid');
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -117,7 +117,7 @@
 block discarded – undo
117 117
         $this->session = [
118 118
             "section_map" => false,
119 119
             "prices_map" => false,
120
-            "work_dir" => pathinfo($this->config['path'], PATHINFO_DIRNAME) . DIRECTORY_SEPARATOR
120
+            "work_dir" => pathinfo($this->config['path'], PATHINFO_DIRNAME).DIRECTORY_SEPARATOR
121 121
         ];
122 122
 
123 123
         $this->read();
Please login to merge, or discard this patch.
src/Search/Command/ReIndexCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@
 block discarded – undo
59 59
 
60 60
             if (is_array($searchResult) && $searchResult['MODULE'] == 'main') {
61 61
                 list(, $path) = explode("|", $searchResult["ID"], 2);
62
-                $output->writeln("\r       " . $path, OutputInterface::VERBOSITY_VERBOSE);
62
+                $output->writeln("\r       ".$path, OutputInterface::VERBOSITY_VERBOSE);
63 63
             }
64 64
         } while (is_array($searchResult));
65 65
 
Please login to merge, or discard this patch.
src/Application/CanRestartTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
      */
32 32
     protected function restartScript(InputInterface $input, OutputInterface $output)
33 33
     {
34
-        $proc = popen('php -f ' . join(' ', $GLOBALS['argv']) . ' 2>&1', 'r');
34
+        $proc = popen('php -f '.join(' ', $GLOBALS['argv']).' 2>&1', 'r');
35 35
         while (!feof($proc)) {
36 36
             $output->write(fread($proc, 4096));
37 37
         }
Please login to merge, or discard this patch.
src/Iblock/Exporter.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -104,8 +104,8 @@  discard block
 block discarded – undo
104 104
         $this->session = [
105 105
             "property_map" => false,
106 106
             "section_map" => false,
107
-            "work_dir" => $pathinfo['dirname'] . DIRECTORY_SEPARATOR,
108
-            "file_dir" => $pathinfo['filename'] . "_files" . DIRECTORY_SEPARATOR,
107
+            "work_dir" => $pathinfo['dirname'].DIRECTORY_SEPARATOR,
108
+            "file_dir" => $pathinfo['filename']."_files".DIRECTORY_SEPARATOR,
109 109
         ];
110 110
 
111 111
         $this->export();
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
     protected function export()
121 121
     {
122 122
         $filesystem = new Filesystem();
123
-        $handle = fopen($this->config['path'] . $this->prefix, "w");
123
+        $handle = fopen($this->config['path'].$this->prefix, "w");
124 124
 
125 125
         $checkPermissions = true;
126 126
         if (PHP_SAPI == 'cli') {
@@ -170,6 +170,6 @@  discard block
 block discarded – undo
170 170
 
171 171
         fclose($handle);
172 172
         $filesystem->remove($this->config['path']);
173
-        $filesystem->rename($this->config['path'] . $this->prefix, $this->config['path'], true);
173
+        $filesystem->rename($this->config['path'].$this->prefix, $this->config['path'], true);
174 174
     }
175 175
 }
176 176
\ No newline at end of file
Please login to merge, or discard this patch.