Completed
Push — master ( 9eb332...ef5bef )
by Arne
02:27
created
src/OperationListBuilder/OperationListBuilderInterface.php 1 patch
Doc Comments   -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,6 @@
 block discarded – undo
17 17
      *
18 18
      * @param Index $mergedIndex
19 19
      * @param Index $localIndex
20
-     * @param Index|null $remoteIndex
21 20
      * @return OperationList
22 21
      */
23 22
     public function buildOperationList(Index $mergedIndex, Index $localIndex): OperationList;
Please login to merge, or discard this patch.
src/IndexMerger/StandardIndexMerger.php 2 patches
Doc Comments   +12 added lines patch added patch discarded remove patch
@@ -100,6 +100,10 @@  discard block
 block discarded – undo
100 100
         return $mergedIndex;
101 101
     }
102 102
 
103
+    /**
104
+     * @param IndexObject|null $localObject
105
+     * @param IndexObject|null $lastLocalObject
106
+     */
103 107
     protected function isLocalObjectModified(?IndexObject $localObject, ?IndexObject $lastLocalObject, int $options): bool
104 108
     {
105 109
         if (!$lastLocalObject)
@@ -132,6 +136,10 @@  discard block
 block discarded – undo
132 136
         return $localObjectModified;
133 137
     }
134 138
 
139
+    /**
140
+     * @param IndexObject|null $remoteObject
141
+     * @param IndexObject|null $lastLocalObject
142
+     */
135 143
     protected function isRemoteObjectModified(?IndexObject $remoteObject, ?IndexObject $lastLocalObject): bool
136 144
     {
137 145
         if ($lastLocalObject)
@@ -144,6 +152,10 @@  discard block
 block discarded – undo
144 152
         }
145 153
     }
146 154
 
155
+    /**
156
+     * @param IndexObject|null $localObject
157
+     * @param IndexObject|null $lastLocalObject
158
+     */
147 159
     protected function resolveConflict(ConflictHandlerInterface $conflictHandler, IndexObject $remoteObject, ?IndexObject $localObject, ?IndexObject $lastLocalObject): IndexObject
148 160
     {
149 161
         $this->logger->notice("Resolving conflict at {$remoteObject->getRelativePath()}...");
Please login to merge, or discard this patch.
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -75,12 +75,10 @@  discard block
 block discarded – undo
75 75
             if ($localObjectModified && $remoteObjectModified)
76 76
             {
77 77
                 $mergedIndex->addObject($this->resolveConflict($conflictHandler, $remoteObject, $localObject, $lastLocalObject));
78
-            }
79
-            elseif ($localObjectModified && $localObject !== null)
78
+            } elseif ($localObjectModified && $localObject !== null)
80 79
             {
81 80
                 $mergedIndex->addObject($localObject);
82
-            }
83
-            elseif ($remoteObjectModified && $remoteObject !== null)
81
+            } elseif ($remoteObjectModified && $remoteObject !== null)
84 82
             {
85 83
                 $mergedIndex->addObject($remoteObject);
86 84
             }
@@ -137,8 +135,7 @@  discard block
 block discarded – undo
137 135
         if ($lastLocalObject)
138 136
         {
139 137
             return !$lastLocalObject->equals($remoteObject, IndexObject::CMP_IGNORE_BLOBID | IndexObject::CMP_IGNORE_INODE);
140
-        }
141
-        else
138
+        } else
142 139
         {
143 140
             return $remoteObject !== null;
144 141
         }
Please login to merge, or discard this patch.
src/Index/Comparison/IndexObjectComparison.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -35,12 +35,10 @@
 block discarded – undo
35 35
         if ($indexObjectA instanceof IndexObject)
36 36
         {
37 37
             $this->relativePath = $indexObjectA->getRelativePath();
38
-        }
39
-        elseif ($indexObjectB instanceof IndexObject)
38
+        } elseif ($indexObjectB instanceof IndexObject)
40 39
         {
41 40
             $this->relativePath = $indexObjectB->getRelativePath();
42
-        }
43
-        else
41
+        } else
44 42
         {
45 43
             throw new \LogicException();
46 44
         }
Please login to merge, or discard this patch.
src/Index/IndexObject.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -233,8 +233,7 @@
 block discarded – undo
233 233
                 "size: {$this->size}",
234 234
                 "blobId: {$blobId}",
235 235
             ]);
236
-        }
237
-        elseif ($this->isLink())
236
+        } elseif ($this->isLink())
238 237
         {
239 238
             $parts = array_merge($parts, [
240 239
                 "target: {$this->linkTarget}",
Please login to merge, or discard this patch.
src/LockAdapter/StorageBasedLockAdapter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
 
46 46
         $started = time();
47 47
 
48
-        while(true)
48
+        while (true)
49 49
         {
50 50
             $this->logger->debug("Checking lock existence for '{$name}'...");
51 51
 
Please login to merge, or discard this patch.
src/Cli/Command/DiffCommand.php 1 patch
Braces   +3 added lines, -7 removed lines patch added patch discarded remove patch
@@ -57,12 +57,10 @@  discard block
 block discarded – undo
57 57
             $this->consoleStyle->error("Invalid argument compareTo given.");
58 58
 
59 59
             return 1;
60
-        }
61
-        elseif ($compareTo === null)
60
+        } elseif ($compareTo === null)
62 61
         {
63 62
             $compareToIndex = $storeman->getLocalIndex();
64
-        }
65
-        else
63
+        } else
66 64
         {
67 65
             $vault = $vaults->getPrioritizedVault($vaults->getVaultsHavingRevision($compareTo));
68 66
 
@@ -101,9 +99,7 @@  discard block
 block discarded – undo
101 99
             $table->render();
102 100
 
103 101
             $output->write("\n");
104
-        }
105
-
106
-        else
102
+        } else
107 103
         {
108 104
             $output->writeln("No differences found.");
109 105
         }
Please login to merge, or discard this patch.
src/Cli/Command/ShowIndexCommand.php 1 patch
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -34,16 +34,13 @@
 block discarded – undo
34 34
 
35 35
                 return 0;
36 36
             }
37
-        }
38
-        elseif ($revision === 'local')
37
+        } elseif ($revision === 'local')
39 38
         {
40 39
             $index = $storeman->getLocalIndex();
41
-        }
42
-        elseif (ctype_digit($revision))
40
+        } elseif (ctype_digit($revision))
43 41
         {
44 42
             $revision = intval($revision);
45
-        }
46
-        else
43
+        } else
47 44
         {
48 45
             $this->consoleStyle->error("Argument 'revision' invalid.");
49 46
 
Please login to merge, or discard this patch.