Completed
Pull Request — master (#28253)
by Tom
10:38
created
lib/private/Repair/RepairMismatchFileCachePath.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,6 @@
 block discarded – undo
24 24
 use OCP\Migration\IOutput;
25 25
 use OCP\Migration\IRepairStep;
26 26
 use Doctrine\DBAL\Platforms\MySqlPlatform;
27
-use OCP\DB\QueryBuilder\IQueryBuilder;
28 27
 use Doctrine\DBAL\Platforms\OraclePlatform;
29 28
 use OCP\Files\IMimeTypeLoader;
30 29
 use OCP\IDBConnection;
Please login to merge, or discard this patch.
Doc Comments   +14 added lines, -1 removed lines patch added patch discarded remove patch
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
 	 * @param string $wrongPath wrong path of the entry to fix
97 97
 	 * @param int $correctStorageNumericId numeric idea of the correct storage
98 98
 	 * @param string $correctPath value to which to set the path of the entry 
99
-	 * @return bool true for success
99
+	 * @return boolean|null true for success
100 100
 	 */
101 101
 	private function fixEntryPath(IOutput $out, $fileId, $wrongPath, $correctStorageNumericId, $correctPath) {
102 102
 		// delete target if exists
@@ -121,6 +121,9 @@  discard block
 block discarded – undo
121 121
 		$out->advance(1, $text);
122 122
 	}
123 123
 
124
+	/**
125
+	 * @param IQueryBuilder $qb
126
+	 */
124 127
 	private function addQueryConditionsParentIdWrongPath($qb, $storageNumericId) {
125 128
 		// thanks, VicDeo!
126 129
 		if ($this->connection->getDatabasePlatform() instanceof MySqlPlatform) {
@@ -160,6 +163,9 @@  discard block
 block discarded – undo
160 163
 		}
161 164
 	}
162 165
 
166
+	/**
167
+	 * @param IQueryBuilder $qb
168
+	 */
163 169
 	private function addQueryConditionsNonExistingParentIdEntry($qb, $storageNumericId = null) {
164 170
 		// Subquery for parent existence
165 171
 		$qbe = $this->connection->getQueryBuilder();
@@ -189,6 +195,9 @@  discard block
 block discarded – undo
189 195
 		}
190 196
 	}
191 197
 
198
+	/**
199
+	 * @param integer $storageNumericId
200
+	 */
192 201
 	private function countResultsToProcessParentIdWrongPath($storageNumericId = null) {
193 202
 		$qb = $this->connection->getQueryBuilder();
194 203
 		$qb->select($qb->createFunction('COUNT(*)'));
@@ -199,6 +208,9 @@  discard block
 block discarded – undo
199 208
 		return $count;
200 209
 	}
201 210
 
211
+	/**
212
+	 * @param integer $storageNumericId
213
+	 */
202 214
 	private function countResultsToProcessNonExistingParentIdEntry($storageNumericId = null) {
203 215
 		$qb = $this->connection->getQueryBuilder();
204 216
 		$qb->select($qb->createFunction('COUNT(*)'));
@@ -347,6 +359,7 @@  discard block
 block discarded – undo
347 359
 	 *
348 360
 	 * @param int $storageId storage id
349 361
 	 * @param string $path path for which to create the parent entry
362
+	 * @param integer $reuseFileId
350 363
 	 * @return int file id of the newly created parent
351 364
 	 */
352 365
 	private function getOrCreateEntry($storageId, $path, $reuseFileId = null) {
Please login to merge, or discard this patch.