Completed
Push — master ( 857202...d87b02 )
by Harry
03:21
created
src/Node/LocalFile.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use Graze\DataFile\Modify\Compress\CompressionType;
6 6
 use League\Flysystem\Adapter\Local;
7
-use League\Flysystem\Filesystem;
8 7
 
9 8
 class LocalFile extends FileNode implements LocalFileNodeInterface
10 9
 {
Please login to merge, or discard this patch.
tests/unit/Format/FormatAwareTraitTest.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace Graze\DataFile\Test\Unit\Format;
4 4
 
5
-use Graze\DataFile\Format\FormatAwareInterface;
6 5
 use Graze\DataFile\Test\Format\FakeFormatAware;
7 6
 use Graze\DataFile\Test\TestCase;
8 7
 use Mockery as m;
Please login to merge, or discard this patch.
tests/unit/Finder/MetadataFinderTest.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,6 @@
 block discarded – undo
9 9
 use Graze\DataFile\Node\FileNode;
10 10
 use Graze\DataFile\Node\FileNodeCollection;
11 11
 use Graze\DataFile\Test\TestCase;
12
-use Hamcrest\Core\AllOf;
13 12
 use Mockery as m;
14 13
 
15 14
 class MetadataFinderTest extends TestCase
Please login to merge, or discard this patch.
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -24,9 +24,9 @@  discard block
 block discarded – undo
24 24
     {
25 25
         $file = m::mock(FileNode::class);
26 26
         $file->shouldReceive('getMetadata')
27
-             ->andReturn([
28
-                 'name' => 'test',
29
-             ]);
27
+                ->andReturn([
28
+                    'name' => 'test',
29
+                ]);
30 30
         $collection = new FileNodeCollection();
31 31
         $collection->add($file);
32 32
 
@@ -41,14 +41,14 @@  discard block
 block discarded – undo
41 41
     {
42 42
         $file = m::mock(FileNode::class);
43 43
         $file->shouldReceive('getMetadata')
44
-             ->andReturn([
45
-                 'name' => 'test',
46
-             ]);
44
+                ->andReturn([
45
+                    'name' => 'test',
46
+                ]);
47 47
         $file2 = m::mock(FileNode::class);
48 48
         $file2->shouldReceive('getMetadata')
49
-              ->andReturn([
50
-                  'name' => 'test2',
51
-              ]);
49
+                ->andReturn([
50
+                    'name' => 'test2',
51
+                ]);
52 52
         $collection = new FileNodeCollection();
53 53
         $collection->add($file);
54 54
         $collection->add($file2);
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
     {
68 68
         $file = m::mock(FileNode::class);
69 69
         $file->shouldReceive('getMetadata')
70
-             ->andReturn(false);
70
+                ->andReturn(false);
71 71
         $collection = new FileNodeCollection();
72 72
         $collection->add($file);
73 73
 
Please login to merge, or discard this patch.
src/Finder/MetadataFinder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
      */
30 30
     public function findFiles(FileNodeCollectionInterface $files)
31 31
     {
32
-        return $files->filter(function (FileNode $file) {
32
+        return $files->filter(function(FileNode $file) {
33 33
             $metadata = $file->getMetadata();
34 34
             if ($metadata) {
35 35
                 return ($this->filter->matches($file->getMetadata()));
Please login to merge, or discard this patch.
src/Modify/Compress/AbstractCompressor.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -40,8 +40,8 @@  discard block
 block discarded – undo
40 40
         }
41 41
 
42 42
         $outputFile = $node->getClone()
43
-                           ->setPath($pathInfo['dirname'] . '/' . $pathInfo['filename'] . '.' . $this->getExtension())
44
-                           ->setCompression($this->getCompression());
43
+                            ->setPath($pathInfo['dirname'] . '/' . $pathInfo['filename'] . '.' . $this->getExtension())
44
+                            ->setCompression($this->getCompression());
45 45
 
46 46
         $this->log(LogLevel::INFO, "Compressing file: {file} into {target} using {compression}", [
47 47
             'file'        => $node,
@@ -76,8 +76,8 @@  discard block
 block discarded – undo
76 76
         }
77 77
 
78 78
         $outputFile = $node->getClone()
79
-                           ->setPath($pathInfo['dirname'] . '/' . $pathInfo['filename'])
80
-                           ->setCompression(CompressionType::NONE);
79
+                            ->setPath($pathInfo['dirname'] . '/' . $pathInfo['filename'])
80
+                            ->setCompression(CompressionType::NONE);
81 81
 
82 82
         $this->log(LogLevel::INFO, "DeCompressing file: {file} into {target} using {compression}", [
83 83
             'file'        => $node,
Please login to merge, or discard this patch.
src/Modify/Contract/MergeFiles.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
 
68 68
         $this->log(LogLevel::INFO, "Merging files in collection $files into: {$target}");
69 69
 
70
-        $filePaths = $files->map(function (LocalFile $item) {
70
+        $filePaths = $files->map(function(LocalFile $item) {
71 71
             return $item->getPath();
72 72
         });
73 73
 
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
 
106 106
         if (!$keepOld) {
107 107
             $this->log(LogLevel::DEBUG, "Deleting old files in collection $files");
108
-            $files->map(function (LocalFile $item) {
108
+            $files->map(function(LocalFile $item) {
109 109
                 if ($item->exists()) {
110 110
                     $item->delete();
111 111
                 }
Please login to merge, or discard this patch.
src/Modify/ConvertEncoding.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -51,8 +51,8 @@
 block discarded – undo
51 51
         );
52 52
 
53 53
         $output = $file->getClone()
54
-                       ->setPath($pathInfo['dirname'] . '/' . $outputFileName)
55
-                       ->setEncoding($encoding);
54
+                        ->setPath($pathInfo['dirname'] . '/' . $outputFileName)
55
+                        ->setEncoding($encoding);
56 56
 
57 57
         $cmd = "iconv " .
58 58
             ($file->getEncoding() ? "--from-code={$file->getEncoding()} " : '') .
Please login to merge, or discard this patch.
src/Modify/Tail.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@
 block discarded – undo
88 88
         $outputFilePath = $pathInfo['dirname'] . '/' . $outputFileName;
89 89
 
90 90
         $output = $file->getClone()
91
-                       ->setPath($outputFilePath);
91
+                        ->setPath($outputFilePath);
92 92
 
93 93
         $this->log(LogLevel::INFO, "Retrieving the last {lines} from file {file}", [
94 94
             'lines' => $this->lines,
Please login to merge, or discard this patch.
src/Node/FileNodeCollection.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
             return null;
24 24
         }
25 25
 
26
-        $commonPath = $this->reduce(function ($commonPath, FileNodeInterface $file) {
26
+        $commonPath = $this->reduce(function($commonPath, FileNodeInterface $file) {
27 27
             if (is_null($commonPath)) {
28 28
                 return $file->getPath();
29 29
             }
Please login to merge, or discard this patch.