Completed
Pull Request — master (#2)
by Tomáš
04:18
created
src/Bundle/TwigBundle/FlexibleExtensionFilesystemLoader.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -43,21 +43,21 @@
 block discarded – undo
43 43
      */
44 44
     public function __construct($sourceDir, array $sourcePaths, array $paths, array $extensions)
45 45
     {
46
-        $mappedSourcePaths = array_map(function ($path) use ($sourceDir) {
46
+        $mappedSourcePaths = array_map(function($path) use ($sourceDir) {
47 47
             return $sourceDir.'/'.$path;
48 48
         }, $sourcePaths);
49 49
 
50 50
         $allPaths = array_merge(
51
-            array_filter($mappedSourcePaths, function ($path) {
51
+            array_filter($mappedSourcePaths, function($path) {
52 52
                 return file_exists($path);
53 53
             }),
54
-            array_filter($paths, function ($path) {
54
+            array_filter($paths, function($path) {
55 55
                 return file_exists($path);
56 56
             })
57 57
         );
58 58
 
59 59
         $this->filesystemLoader = new FilesystemLoader($allPaths);
60
-        $this->extensions = array_map(function ($ext) {
60
+        $this->extensions = array_map(function($ext) {
61 61
             return $ext ? '.'.$ext : $ext;
62 62
         }, $extensions);
63 63
     }
Please login to merge, or discard this patch.
src/Core/Sculpin.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
 
148 148
         $this->eventDispatcher->dispatch(self::EVENT_BEFORE_RUN, new SourceSetEvent($sourceSet));
149 149
 
150
-        if ($updatedSources = array_filter($sourceSet->updatedSources(), function ($source) {
150
+        if ($updatedSources = array_filter($sourceSet->updatedSources(), function($source) {
151 151
             return !$source->isGenerated();
152 152
         })) {
153 153
             if (!$found) {
@@ -163,7 +163,7 @@  discard block
 block discarded – undo
163 163
             $timer = microtime(true);
164 164
             foreach ($updatedSources as $source) {
165 165
                 $this->generatorManager->generate($source, $sourceSet);
166
-                $io->overwrite(sprintf('%3d%%', 100 * ((++$counter) / $total)), false);
166
+                $io->overwrite(sprintf('%3d%%', 100*((++$counter)/$total)), false);
167 167
             }
168 168
             $io->write(sprintf(' (%d sources / %4.2f seconds)', $total, microtime(true) - $timer));
169 169
         }
@@ -192,7 +192,7 @@  discard block
 block discarded – undo
192 192
                 if ($source->canBeFormatted()) {
193 193
                     $source->data()->set('blocks', $this->formatterManager->formatSourceBlocks($source));
194 194
                 }
195
-                $io->overwrite(sprintf('%3d%%', 100 * ((++$counter) / $total)), false);
195
+                $io->overwrite(sprintf('%3d%%', 100*((++$counter)/$total)), false);
196 196
             }
197 197
             $io->write(sprintf(' (%d sources / %4.2f seconds)', $total, microtime(true) - $timer));
198 198
         }
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
                 } else {
216 216
                     $source->setFormattedContent($source->content());
217 217
                 }
218
-                $io->overwrite(sprintf('%3d%%', 100 * ((++$counter) / $total)), false);
218
+                $io->overwrite(sprintf('%3d%%', 100*((++$counter)/$total)), false);
219 219
             }
220 220
             $this->eventDispatcher->dispatch(self::EVENT_AFTER_FORMAT, new SourceSetEvent($sourceSet));
221 221
             $io->write(sprintf(' (%d sources / %4.2f seconds)', $total, microtime(true) - $timer));
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,6 @@
 block discarded – undo
17 17
 use Sculpin\Core\Formatter\FormatterManager;
18 18
 use Sculpin\Core\Generator\GeneratorManager;
19 19
 use Sculpin\Core\Io\IoInterface;
20
-use Sculpin\Core\Io\NullIo;
21 20
 use Sculpin\Core\Output\SourceOutput;
22 21
 use Sculpin\Core\Output\WriterInterface;
23 22
 use Sculpin\Core\Permalink\SourcePermalinkFactoryInterface;
Please login to merge, or discard this patch.
DependencyInjection/Compiler/RegisterKernelListenersPass.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
                     $event['method'] = 'on'.preg_replace_callback([
44 44
                         '/(?<=\b)[a-z]/i',
45 45
                         '/[^a-z0-9]/i',
46
-                    ], function ($matches) {
46
+                    ], function($matches) {
47 47
                         return strtoupper($matches[0]);
48 48
                     }, $event['event']);
49 49
                     $event['method'] = preg_replace('/[^a-z0-9]/i', '', $event['method']);
Please login to merge, or discard this patch.
src/Core/DataProvider/DataProviderManager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@
 block discarded – undo
1 1
 <?php
2 2
 
3
-declare(strict_types=1);
3
+declare(strict_types = 1);
4 4
 
5 5
 /*
6 6
  * This file is a part of Sculpin.
Please login to merge, or discard this patch.