Completed
Push — master ( 69ed36...4b8ba8 )
by BruceScrutinizer
02:06
created
src/Entry/Entry.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
         Assert::notEmpty($entry);
17 17
 
18 18
         $this->originalEntry = $entry;
19
-        $this->entry =  $entry;
19
+        $this->entry = $entry;
20 20
     }
21 21
 
22 22
     public function equalTo(self $other): bool
Please login to merge, or discard this patch.
src/Scanner/ComposerJson.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -40,20 +40,20 @@
 block discarded – undo
40 40
 
41 41
 
42 42
         for ($i = 0; $i < $countMax; $i++) {
43
-            $pathComposer = \getcwd() .DIRECTORY_SEPARATOR. $relativePath;
43
+            $pathComposer = \getcwd() . DIRECTORY_SEPARATOR . $relativePath;
44 44
             $realPath = \safe\realpath($pathComposer . self::COMPOSER_JSON);
45 45
 
46 46
             if (\is_readable($realPath) === false) {
47
-                $relativePath .= '..'.DIRECTORY_SEPARATOR;
47
+                $relativePath .= '..' . DIRECTORY_SEPARATOR;
48 48
                 continue;
49 49
             }
50 50
 
51 51
             $jsonArray = \safe\json_decode(
52
-                \safe\file_get_contents($pathComposer.DIRECTORY_SEPARATOR.self::COMPOSER_JSON),
52
+                \safe\file_get_contents($pathComposer . DIRECTORY_SEPARATOR . self::COMPOSER_JSON),
53 53
                 true
54 54
             );
55 55
 
56
-            if ($jsonArray['name']!==self::NAME_PROJECT) {
56
+            if ($jsonArray['name'] !== self::NAME_PROJECT) {
57 57
                 return new FileSystemPath($pathComposer);
58 58
             }
59 59
         }
Please login to merge, or discard this patch.
src/Result/Result.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@
 block discarded – undo
11 11
     /** @var int  */
12 12
     private $type;
13 13
 
14
-    public function __construct(string $value, int $type=0)
14
+    public function __construct(string $value, int $type = 0)
15 15
     {
16 16
         $this->value = $value;
17 17
         $this->type = $type;
Please login to merge, or discard this patch.
src/Command/NamespaceProtectorCommand.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -9,15 +9,15 @@
 block discarded – undo
9 9
 {
10 10
     protected function execute(InputInterface $input, OutputInterface $output): int
11 11
     {
12
-        $script_start =  $this->startWatch();
12
+        $script_start = $this->startWatch();
13 13
 
14 14
         $returnValue = parent::execute($input, $output);
15 15
 
16 16
         $elapsed_time = $this->stopWatch($script_start);
17 17
 
18
-        $output->writeln("<fg=green>Elapsed time: ".$elapsed_time.'</>');
18
+        $output->writeln("<fg=green>Elapsed time: " . $elapsed_time . '</>');
19 19
 
20
-        return $returnValue ;
20
+        return $returnValue;
21 21
     }
22 22
 
23 23
     private function startWatch(): float
Please login to merge, or discard this patch.
src/Common/FileSystemPath.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@
 block discarded – undo
9 9
     /** @var string  */
10 10
     private $path;
11 11
 
12
-    public function __construct(string $path, bool $noCheck=false)
12
+    public function __construct(string $path, bool $noCheck = false)
13 13
     {
14 14
         if ($noCheck === false) {
15 15
             Assert::readable($path);
Please login to merge, or discard this patch.
src/Config/ConfigTemplateCreator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,12 +8,12 @@
 block discarded – undo
8 8
 final class ConfigTemplateCreator
9 9
 {
10 10
     private const FILENAME = 'namespace-protector-config.json';
11
-    private const FILENAME_VISIBILITY =  'namespace-protector-visibility.json';
11
+    private const FILENAME_VISIBILITY = 'namespace-protector-visibility.json';
12 12
     private const TEMPLATE_CONFIG_JSON = 'template-config-json';
13 13
 
14 14
     public static function createJsonTemplateConfig(PathInterface $baseComposerJsonDirectory): void
15 15
     {
16
-        self::createFileWithBackup($baseComposerJsonDirectory().self::FILENAME, self::TEMPLATE_CONFIG_JSON);
16
+        self::createFileWithBackup($baseComposerJsonDirectory() . self::FILENAME, self::TEMPLATE_CONFIG_JSON);
17 17
     }
18 18
 
19 19
     public static function createJsonTemplateVisibility(): void
Please login to merge, or discard this patch.
src/Db/BooleanMatchPos.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@
 block discarded – undo
13 13
     public function evaluate(Iterable $data, Entry $matchMe): bool
14 14
     {
15 15
         foreach ($data as $entry => $value) {
16
-            if (strpos($matchMe->get(), $entry) !==false) {
16
+            if (strpos($matchMe->get(), $entry) !== false) {
17 17
                 return true;
18 18
             }
19 19
         }
Please login to merge, or discard this patch.
src/Config/Config.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -97,7 +97,7 @@
 block discarded – undo
97 97
             '' . PHP_EOL .
98 98
             '|Dump config:' . PHP_EOL .
99 99
             '|> Version: ' . $this->getVersion() . PHP_EOL .
100
-            '|> Cache: ' . ($this->enabledCache() === true ? "TRUE": "FALSE")  . PHP_EOL .
100
+            '|> Cache: ' . ($this->enabledCache() === true ? "TRUE" : "FALSE") . PHP_EOL .
101 101
             '|> Path start: ' . $this->pathStart->get() . PHP_EOL .
102 102
             '|> Composer Json path: ' . $this->pathComposerJson->get() . PHP_EOL .
103 103
             '|> Mode: ' . $this->getMode() . PHP_EOL .
Please login to merge, or discard this patch.
src/Command/AbstractValidateNamespaceCommand.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
     protected function execute(InputInterface $input, OutputInterface $output)
28 28
     {
29 29
         $output->writeln("Boot validate analysis....");
30
-        $config = Config::loadFromFile(new FileSystemPath(\getcwd().'/namespace-protector-config.json'));
30
+        $config = Config::loadFromFile(new FileSystemPath(\getcwd() . '/namespace-protector-config.json'));
31 31
         $factory = new NamespaceProtectorProcessorFactory();
32 32
         $namespaceProtectorProcessor = $factory->create($config);
33 33
 
@@ -42,9 +42,9 @@  discard block
 block discarded – undo
42 42
         $output->writeln('Start analysis...');
43 43
         $namespaceProtectorProcessor->process();
44 44
 
45
-        $output->writeln('<fg=red>Total errors: ' . $namespaceProtectorProcessor->getCountErrors().'</>');
45
+        $output->writeln('<fg=red>Total errors: ' . $namespaceProtectorProcessor->getCountErrors() . '</>');
46 46
 
47
-        if ($namespaceProtectorProcessor->getCountErrors()>0) {
47
+        if ($namespaceProtectorProcessor->getCountErrors() > 0) {
48 48
             return self::FAILURE;
49 49
         }
50 50
 
Please login to merge, or discard this patch.