Completed
Pull Request — master (#362)
by Maxence
01:49
created
lib/Service/CirclesService.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -510,24 +510,24 @@
 block discarded – undo
510 510
 		switch ($type) {
511 511
 			case Circle::CIRCLES_PERSONAL:
512 512
 				return $urlGen->getAbsoluteURL(
513
-					$urlGen->imagePath(Application::APP_NAME, 'personal' . $ext)
513
+					$urlGen->imagePath(Application::APP_NAME, 'personal'.$ext)
514 514
 				);
515 515
 			case Circle::CIRCLES_CLOSED:
516 516
 				return $urlGen->getAbsoluteURL(
517
-					$urlGen->imagePath(Application::APP_NAME, 'closed' . $ext)
517
+					$urlGen->imagePath(Application::APP_NAME, 'closed'.$ext)
518 518
 				);
519 519
 			case Circle::CIRCLES_SECRET:
520 520
 				return $urlGen->getAbsoluteURL(
521
-					$urlGen->imagePath(Application::APP_NAME, 'secret' . $ext)
521
+					$urlGen->imagePath(Application::APP_NAME, 'secret'.$ext)
522 522
 				);
523 523
 			case Circle::CIRCLES_PUBLIC:
524 524
 				return $urlGen->getAbsoluteURL(
525
-					$urlGen->imagePath(Application::APP_NAME, 'black_circle' . $ext)
525
+					$urlGen->imagePath(Application::APP_NAME, 'black_circle'.$ext)
526 526
 				);
527 527
 		}
528 528
 
529 529
 		return $urlGen->getAbsoluteURL(
530
-			$urlGen->imagePath(Application::APP_NAME, 'black_circle' . $ext)
530
+			$urlGen->imagePath(Application::APP_NAME, 'black_circle'.$ext)
531 531
 		);
532 532
 	}
533 533
 
Please login to merge, or discard this patch.
lib/ShareByCircleProvider.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -300,19 +300,19 @@  discard block
 block discarded – undo
300 300
 	 */
301 301
 	private function createShare($share) {
302 302
 		$this->miscService->log(
303
-			'Creating share (1/4) - type: ' . $share->getShareType() . ' - token: '
304
-			. $share->getToken() . ' - type: ' . $share->getShareType() . ' - with: '
305
-			. $share->getSharedWith() . ' - permissions: ' . $share->getPermissions(), 0
303
+			'Creating share (1/4) - type: '.$share->getShareType().' - token: '
304
+			. $share->getToken().' - type: '.$share->getShareType().' - with: '
305
+			. $share->getSharedWith().' - permissions: '.$share->getPermissions(), 0
306 306
 		);
307 307
 
308 308
 		$qb = $this->getBaseInsertSql($share);
309
-		$this->miscService->log('Share creation (2/4) : ' . json_encode($qb->getSQL()), 0);
309
+		$this->miscService->log('Share creation (2/4) : '.json_encode($qb->getSQL()), 0);
310 310
 
311 311
 		$result = $qb->execute();
312
-		$this->miscService->log('Share creation result (3/4) : ' . json_encode($result), 0);
312
+		$this->miscService->log('Share creation result (3/4) : '.json_encode($result), 0);
313 313
 
314 314
 		$id = $qb->getLastInsertId();
315
-		$this->miscService->log('Share created ID (4/4) : ' . $id, 0);
315
+		$this->miscService->log('Share created ID (4/4) : '.$id, 0);
316 316
 
317 317
 		try {
318 318
 			$share->setId($id);
@@ -537,7 +537,7 @@  discard block
 block discarded – undo
537 537
 	public function getShareByToken($token) {
538 538
 		$qb = $this->dbConnection->getQueryBuilder();
539 539
 
540
-		$this->miscService->log("Opening share by token '#" . $token . "'", 0);
540
+		$this->miscService->log("Opening share by token '#".$token."'", 0);
541 541
 
542 542
 		$cursor = $qb->select('*')
543 543
 					 ->from('share')
@@ -561,7 +561,7 @@  discard block
 block discarded – undo
561 561
 			try {
562 562
 				$data = $this->getShareByPersonalToken($token);
563 563
 			} catch (Exception $e) {
564
-				$this->miscService->log("Share '#" . $token . "' not found.", 0);
564
+				$this->miscService->log("Share '#".$token."' not found.", 0);
565 565
 				throw new ShareNotFound('Share not found', $this->l10n->t('Could not find share'));
566 566
 			}
567 567
 		}
@@ -570,7 +570,7 @@  discard block
 block discarded – undo
570 570
 			$share = $this->createShareObject($data);
571 571
 		} catch (InvalidShare $e) {
572 572
 			$this->miscService->log(
573
-				"Share Object '#" . $token . "' not created. " . json_encode($data), 0
573
+				"Share Object '#".$token."' not created. ".json_encode($data), 0
574 574
 			);
575 575
 			throw new ShareNotFound('Share not found', $this->l10n->t('Could not find share'));
576 576
 		}
Please login to merge, or discard this patch.
lib/Model/GlobalScale/GSEvent.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -94,7 +94,7 @@
 block discarded – undo
94 94
 	}
95 95
 
96 96
 	/**
97
-	 * @param mixed $type
97
+	 * @param string $type
98 98
 	 *
99 99
 	 * @return GSEvent
100 100
 	 */
Please login to merge, or discard this patch.
lib/Service/ConfigService.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -212,7 +212,7 @@  discard block
 block discarded – undo
212 212
 		if ((!$this->isNonSSLLinksAllowed() || strpos($remote, 'http://') !== 0)
213 213
 			&& strpos($remote, 'https://') !== 0
214 214
 		) {
215
-			$remote = 'https://' . $remote;
215
+			$remote = 'https://'.$remote;
216 216
 		}
217 217
 
218 218
 		return rtrim($remote, '/');
@@ -399,7 +399,7 @@  discard block
 block discarded – undo
399 399
 				return false;
400 400
 			}
401 401
 
402
-			throw new GSStatusException('GS and lookup are not configured : ' . $lookup . ', ' . $enabled);
402
+			throw new GSStatusException('GS and lookup are not configured : '.$lookup.', '.$enabled);
403 403
 		}
404 404
 
405 405
 		$clef = $this->config->getSystemValue('gss.jwt.key', '');
Please login to merge, or discard this patch.
Doc Comments   +1 added lines patch added patch discarded remove patch
@@ -440,6 +440,7 @@
 block discarded – undo
440 440
 	 * @param string $type
441 441
 	 *
442 442
 	 * @throws GSStatusException
443
+	 * @return string
443 444
 	 */
444 445
 	public function getGSStatus(string $type = '') {
445 446
 		$enabled = $this->config->getSystemValueBool('gs.enabled', false);
Please login to merge, or discard this patch.
lib/Search/GlobalScaleUsers.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -98,7 +98,7 @@
 block discarded – undo
98 98
 		RequestServerException |
99 99
 		RequestResultNotJsonException $e
100 100
 		) {
101
-			$this->miscService->log('Issue while retrieving instances from lookup: ' . $e->getMessage());
101
+			$this->miscService->log('Issue while retrieving instances from lookup: '.$e->getMessage());
102 102
 
103 103
 			return [];
104 104
 		}
Please login to merge, or discard this patch.
lib/Model/BaseCircle.php 1 patch
Doc Comments   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -406,7 +406,7 @@  discard block
 block discarded – undo
406 406
 	}
407 407
 
408 408
 	/**
409
-	 * @return string
409
+	 * @return integer
410 410
 	 */
411 411
 	public function getType() {
412 412
 		return $this->type;
@@ -460,7 +460,7 @@  discard block
 block discarded – undo
460 460
 	}
461 461
 
462 462
 	/**
463
-	 * @return array
463
+	 * @return Member[]
464 464
 	 */
465 465
 	public function getGroups() {
466 466
 		return $this->groups;
@@ -478,7 +478,7 @@  discard block
 block discarded – undo
478 478
 	}
479 479
 
480 480
 	/**
481
-	 * @return array
481
+	 * @return FederatedLink[]
482 482
 	 */
483 483
 	public function getLinks() {
484 484
 		return $this->links;
@@ -514,7 +514,7 @@  discard block
 block discarded – undo
514 514
 //	}
515 515
 
516 516
 	/**
517
-	 * @param integer|string $type
517
+	 * @param string $type
518 518
 	 *
519 519
 	 * @return integer
520 520
 	 */
Please login to merge, or discard this patch.
lib/Controller/GlobalScaleController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -91,7 +91,7 @@
 block discarded – undo
91 91
 			$wrappers = $this->gsUpstreamService->getEventsByToken($token);
92 92
 		} catch (Exception $e) {
93 93
 			$this->miscService->log(
94
-				'exception during async: ' . ['token' => $token, 'error' => $e->getMessage()]
94
+				'exception during async: '.['token' => $token, 'error' => $e->getMessage()]
95 95
 			);
96 96
 			$this->fail(['token' => $token, 'error' => $e->getMessage()]);
97 97
 		}
Please login to merge, or discard this patch.
lib/Service/GSUpstreamService.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
 			}
141 141
 		} catch (Exception $e) {
142 142
 			$this->miscService->log(
143
-				get_class($e) . ' on new event: ' . $e->getMessage() . ' - ' . json_encode($event), 1
143
+				get_class($e).' on new event: '.$e->getMessage().' - '.json_encode($event), 1
144 144
 			);
145 145
 			throw $e;
146 146
 		}
@@ -224,7 +224,7 @@  discard block
 block discarded – undo
224 224
 		$request->setDataSerialize($event);
225 225
 
226 226
 		$result = $this->retrieveJson($request);
227
-		$this->miscService->log('result ' . json_encode($result));
227
+		$this->miscService->log('result '.json_encode($result));
228 228
 		if ($this->getInt('status', $result) === 0) {
229 229
 			throw new GlobalScaleEventException($this->get('error', $result));
230 230
 		}
@@ -337,7 +337,7 @@  discard block
 block discarded – undo
337 337
 
338 338
 			try {
339 339
 				$result = $this->retrieveJson($request);
340
-				$this->miscService->log('result: ' . json_encode($result));
340
+				$this->miscService->log('result: '.json_encode($result));
341 341
 				if ($this->getInt('status', $result, 0) !== 1) {
342 342
 					throw new RequestContentException('result status is not good');
343 343
 				}
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -349,7 +349,7 @@
 block discarded – undo
349 349
 
350 350
 
351 351
 	/**
352
-	 * @param array $circles
352
+	 * @param Circle[] $circles
353 353
 	 *
354 354
 	 * @throws GSStatusException
355 355
 	 */
Please login to merge, or discard this patch.
lib/Service/GlobalScaleService.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -139,16 +139,16 @@  discard block
 block discarded – undo
139 139
 	 * @throws GlobalScaleEventException
140 140
 	 */
141 141
 	public function getGlobalScaleEvent(GSEvent $event): AGlobalScaleEvent {
142
-		$class = '\OCA\Circles\\' . $event->getType();
142
+		$class = '\OCA\Circles\\'.$event->getType();
143 143
 		try {
144 144
 			$gs = OC::$server->query($class);
145 145
 			if (!$gs instanceof AGlobalScaleEvent) {
146
-				throw new GlobalScaleEventException($class . ' not an AGlobalScaleEvent');
146
+				throw new GlobalScaleEventException($class.' not an AGlobalScaleEvent');
147 147
 			}
148 148
 
149 149
 			return $gs;
150 150
 		} catch (QueryException $e) {
151
-			throw new GlobalScaleEventException('AGlobalScaleEvent ' . $class . ' not found');
151
+			throw new GlobalScaleEventException('AGlobalScaleEvent '.$class.' not found');
152 152
 		}
153 153
 	}
154 154
 
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
 		try {
201 201
 			$instances = $this->retrieveJson($request);
202 202
 		} catch (RequestContentException | RequestNetworkException | RequestResultSizeException | RequestServerException | RequestResultNotJsonException $e) {
203
-			$this->miscService->log('Issue while retrieving instances from lookup: ' . $e->getMessage());
203
+			$this->miscService->log('Issue while retrieving instances from lookup: '.$e->getMessage());
204 204
 
205 205
 			return [];
206 206
 		}
Please login to merge, or discard this patch.