Completed
Pull Request — master (#1512)
by Julius
49s
created
lib/Command/CirclesCheck.php 1 patch
Spacing   +37 added lines, -37 removed lines patch added patch discarded remove patch
@@ -177,7 +177,7 @@  discard block
 block discarded – undo
177 177
 			throw new Exception('Please specify a --type for the test');
178 178
 		}
179 179
 		if ($test !== '' && !in_array($type, self::$checks)) {
180
-			throw new Exception('Unknown type: ' . implode(', ', self::$checks));
180
+			throw new Exception('Unknown type: '.implode(', ', self::$checks));
181 181
 		}
182 182
 
183 183
 //		$this->configService->setAppValue(ConfigService::TEST_NC_BASE, $test);
@@ -235,7 +235,7 @@  discard block
 block discarded – undo
235 235
 		}
236 236
 
237 237
 		$output->writeln('');
238
-		$output->writeln('* testing current address: ' . $test);
238
+		$output->writeln('* testing current address: '.$test);
239 239
 
240 240
 		try {
241 241
 			$this->setupLoopback($input, $output, $test);
@@ -271,8 +271,8 @@  discard block
 block discarded – undo
271 271
 				continue;
272 272
 			}
273 273
 
274
-			$loopback = rtrim($scheme . '://' . $cloudId . $path, '/');
275
-			$output->writeln('* testing address: ' . $loopback . ' ');
274
+			$loopback = rtrim($scheme.'://'.$cloudId.$path, '/');
275
+			$output->writeln('* testing address: '.$loopback.' ');
276 276
 
277 277
 			try {
278 278
 				$this->setupLoopback($input, $output, $loopback);
@@ -345,8 +345,8 @@  discard block
 block discarded – undo
345 345
 		$test = new FederatedEvent(LoopbackTest::class);
346 346
 		$this->federatedEventService->newEvent($test);
347 347
 		$output->writeln(
348
-			'<info>' . $test->getWrapperToken() . '</info> ' .
349
-			'(took ' . (round(microtime(true) * 1000) - $timer) . 'ms)'
348
+			'<info>'.$test->getWrapperToken().'</info> '.
349
+			'(took '.(round(microtime(true) * 1000) - $timer).'ms)'
350 350
 		);
351 351
 
352 352
 		$output->writeln('- Waiting for async process to finish (5s)');
@@ -365,18 +365,18 @@  discard block
 block discarded – undo
365 365
 
366 366
 		$checkVerify = $wrapper->getEvent()->getData()->gInt('verify');
367 367
 		if ($checkVerify === LoopbackTest::VERIFY) {
368
-			$output->write('<info>verify=' . $checkVerify . '</info> ');
368
+			$output->write('<info>verify='.$checkVerify.'</info> ');
369 369
 		} else {
370
-			$output->writeln('<error>verify=' . $checkVerify . '</error>');
370
+			$output->writeln('<error>verify='.$checkVerify.'</error>');
371 371
 
372 372
 			return false;
373 373
 		}
374 374
 
375 375
 		$checkManage = $wrapper->getResult()->gInt('manage');
376 376
 		if ($checkManage === LoopbackTest::MANAGE) {
377
-			$output->write('<info>manage=' . $checkManage . '</info> ');
377
+			$output->write('<info>manage='.$checkManage.'</info> ');
378 378
 		} else {
379
-			$output->writeln('<error>manage=' . $checkManage . '</error>');
379
+			$output->writeln('<error>manage='.$checkManage.'</error>');
380 380
 
381 381
 			return false;
382 382
 		}
@@ -415,7 +415,7 @@  discard block
 block discarded – undo
415 415
 		$this->configService->setAppValue(ConfigService::LOOPBACK_CLOUD_ID, $cloudId);
416 416
 		$this->configService->setAppValue(ConfigService::LOOPBACK_CLOUD_PATH, $path);
417 417
 		$output->writeln(
418
-			'- Address <info>' . $loopback . '</info> is now used as <info>loopback</info>'
418
+			'- Address <info>'.$loopback.'</info> is now used as <info>loopback</info>'
419 419
 		);
420 420
 	}
421 421
 
@@ -467,8 +467,8 @@  discard block
 block discarded – undo
467 467
 				continue;
468 468
 			}
469 469
 
470
-			$internal = rtrim($scheme . '://' . $cloudId, '/');
471
-			$fullInternal = rtrim($scheme . '://' . $cloudId . $path, '/');
470
+			$internal = rtrim($scheme.'://'.$cloudId, '/');
471
+			$fullInternal = rtrim($scheme.'://'.$cloudId.$path, '/');
472 472
 
473 473
 			$question = new ConfirmationQuestion(
474 474
 				'<comment>Do you want to check the validity of this internal address?</comment> (Y/n) ', true,
@@ -487,9 +487,9 @@  discard block
 block discarded – undo
487 487
 					'You will need to run this <info>curl</info> command from a terminal on your local network and paste its result: '
488 488
 				);
489 489
 				$output->writeln(
490
-					'     curl -L "' . $internal
490
+					'     curl -L "'.$internal
491 491
 					. '/.well-known/webfinger?resource=http://nextcloud.com/&test='
492
-					. $testToken . '"'
492
+					. $testToken.'"'
493 493
 				);
494 494
 
495 495
 				$output->writeln('paste the result here: ');
@@ -523,7 +523,7 @@  discard block
 block discarded – undo
523 523
 
524 524
 				if ($pastedHref !== $href) {
525 525
 					$output->writeln(
526
-						'<error>The returned data (' . $pastedHref . ') are not the one expected: </error>'
526
+						'<error>The returned data ('.$pastedHref.') are not the one expected: </error>'
527 527
 						. $href
528 528
 					);
529 529
 					continue;
@@ -535,7 +535,7 @@  discard block
 block discarded – undo
535 535
 					'Next step, please run this <info>curl</info> command from a terminal on your local network and paste its result: '
536 536
 				);
537 537
 				$output->writeln(
538
-					'     curl -L "' . $pastedHref . '?test=' . $testToken . '" -H "Accept: application/json"'
538
+					'     curl -L "'.$pastedHref.'?test='.$testToken.'" -H "Accept: application/json"'
539 539
 				);
540 540
 
541 541
 				$output->writeln('paste the result here: ');
@@ -552,9 +552,9 @@  discard block
 block discarded – undo
552 552
 					|| $appSignatory->getRoot() !== $pastedSignatory->g('root')) {
553 553
 					$output->writeln(
554 554
 						'<error>The returned data ('
555
-						. $pastedSignatory->g('uid') . '/' . $pastedSignatory->g('root')
555
+						. $pastedSignatory->g('uid').'/'.$pastedSignatory->g('root')
556 556
 						. ') are not the one expected: </error>'
557
-						. $appSignatory->getUid(true) . '/' . $appSignatory->getRoot()
557
+						. $appSignatory->getUid(true).'/'.$appSignatory->getRoot()
558 558
 					);
559 559
 					continue;
560 560
 				}
@@ -581,7 +581,7 @@  discard block
 block discarded – undo
581 581
 
582 582
 		$output->writeln('');
583 583
 		$question = new ConfirmationQuestion(
584
-			'- Do you want to save <info>' . $internal
584
+			'- Do you want to save <info>'.$internal
585 585
 			. '</info> as your <info>internal</info> address ? (y/N) ',
586 586
 			false, '/^(y|Y)/i'
587 587
 		);
@@ -597,7 +597,7 @@  discard block
 block discarded – undo
597 597
 		$this->configService->setAppValue(ConfigService::INTERNAL_CLOUD_ID, $cloudId);
598 598
 		$this->configService->setAppValue(ConfigService::INTERNAL_CLOUD_PATH, $path);
599 599
 
600
-		$output->writeln('- Address <info>' . $internal . '</info> is now used as <info>internal</info>');
600
+		$output->writeln('- Address <info>'.$internal.'</info> is now used as <info>internal</info>');
601 601
 	}
602 602
 
603 603
 
@@ -649,8 +649,8 @@  discard block
 block discarded – undo
649 649
 				continue;
650 650
 			}
651 651
 
652
-			$frontal = rtrim($scheme . '://' . $cloudId, '/');
653
-			$fullFrontal = rtrim($scheme . '://' . $cloudId . $path, '/');
652
+			$frontal = rtrim($scheme.'://'.$cloudId, '/');
653
+			$fullFrontal = rtrim($scheme.'://'.$cloudId.$path, '/');
654 654
 
655 655
 			$question = new ConfirmationQuestion(
656 656
 				'<comment>Do you want to check the validity of this frontal address?</comment> (y/N) ', false,
@@ -669,9 +669,9 @@  discard block
 block discarded – undo
669 669
 					'You will need to run this <info>curl</info> command from a remote terminal and paste its result: '
670 670
 				);
671 671
 				$output->writeln(
672
-					'     curl -L "' . $frontal
672
+					'     curl -L "'.$frontal
673 673
 					. '/.well-known/webfinger?resource=http://nextcloud.com/&test='
674
-					. $testToken . '"'
674
+					. $testToken.'"'
675 675
 				);
676 676
 
677 677
 
@@ -706,7 +706,7 @@  discard block
 block discarded – undo
706 706
 
707 707
 				if ($pastedHref !== $href) {
708 708
 					$output->writeln(
709
-						'<error>The returned data (' . $pastedHref . ') are not the one expected: </error>'
709
+						'<error>The returned data ('.$pastedHref.') are not the one expected: </error>'
710 710
 						. $href
711 711
 					);
712 712
 					continue;
@@ -718,7 +718,7 @@  discard block
 block discarded – undo
718 718
 					'Next step, please run this <info>curl</info> command from a remote terminal and paste its result: '
719 719
 				);
720 720
 				$output->writeln(
721
-					'     curl -L "' . $pastedHref . '?test=' . $testToken . '" -H "Accept: application/json"'
721
+					'     curl -L "'.$pastedHref.'?test='.$testToken.'" -H "Accept: application/json"'
722 722
 				);
723 723
 
724 724
 				$output->writeln('paste the result here: ');
@@ -736,9 +736,9 @@  discard block
 block discarded – undo
736 736
 					|| $appSignatory->getRoot() !== $pastedSignatory->g('root')) {
737 737
 					$output->writeln(
738 738
 						'<error>The returned data ('
739
-						. $pastedSignatory->g('uid') . '/' . $pastedSignatory->g('root')
739
+						. $pastedSignatory->g('uid').'/'.$pastedSignatory->g('root')
740 740
 						. ') are not the one expected: </error>'
741
-						. $appSignatory->getUid(true) . '/' . $appSignatory->getRoot()
741
+						. $appSignatory->getUid(true).'/'.$appSignatory->getRoot()
742 742
 					);
743 743
 					continue;
744 744
 				}
@@ -765,7 +765,7 @@  discard block
 block discarded – undo
765 765
 
766 766
 		$output->writeln('');
767 767
 		$question = new ConfirmationQuestion(
768
-			'- Do you want to save <info>' . $frontal
768
+			'- Do you want to save <info>'.$frontal
769 769
 			. '</info> as your <info>frontal</info> address ? (y/N) ',
770 770
 			false, '/^(y|Y)/i'
771 771
 		);
@@ -781,7 +781,7 @@  discard block
 block discarded – undo
781 781
 		$this->configService->setAppValue(ConfigService::FRONTAL_CLOUD_ID, $cloudId);
782 782
 		$this->configService->setAppValue(ConfigService::FRONTAL_CLOUD_PATH, $path);
783 783
 
784
-		$output->writeln('- Address <info>' . $frontal . '</info> is now used as <info>frontal</info>');
784
+		$output->writeln('- Address <info>'.$frontal.'</info> is now used as <info>frontal</info>');
785 785
 	}
786 786
 
787 787
 
@@ -807,7 +807,7 @@  discard block
 block discarded – undo
807 807
 			$request->setDataSerialize(new SimpleDataStore(['empty' => 1]));
808 808
 		}
809 809
 
810
-		$output->write('- ' . $type . ' request on ' . $request->getCompleteUrl() . ': ');
810
+		$output->write('- '.$type.' request on '.$request->getCompleteUrl().': ');
811 811
 
812 812
 		try {
813 813
 			$this->doRequest($request);
@@ -818,7 +818,7 @@  discard block
 block discarded – undo
818 818
 				$color = 'info';
819 819
 			}
820 820
 
821
-			$output->writeln('<' . $color . '>' . $result->getStatusCode() . '</' . $color . '>');
821
+			$output->writeln('<'.$color.'>'.$result->getStatusCode().'</'.$color.'>');
822 822
 			if ($result->getStatusCode() === 200) {
823 823
 				return true;
824 824
 			}
@@ -842,7 +842,7 @@  discard block
 block discarded – undo
842 842
 
843 843
 		$output->writeln('');
844 844
 		$output->writeln(
845
-			'The address <info>' . $address . '</info> seems to reach your local Nextcloud.'
845
+			'The address <info>'.$address.'</info> seems to reach your local Nextcloud.'
846 846
 		);
847 847
 
848 848
 		$helper = $this->getHelper('question');
@@ -859,8 +859,8 @@  discard block
 block discarded – undo
859 859
 
860 860
 		$this->configService->setAppValue(ConfigService::FORCE_NC_BASE, $address);
861 861
 		$output->writeln(
862
-			'New configuration <info>' . Application::APP_ID . '.' . ConfigService::FORCE_NC_BASE . '=\''
863
-			. $address . '\'</info> stored in database'
862
+			'New configuration <info>'.Application::APP_ID.'.'.ConfigService::FORCE_NC_BASE.'=\''
863
+			. $address.'\'</info> stored in database'
864 864
 		);
865 865
 	}
866 866
 
@@ -888,7 +888,7 @@  discard block
 block discarded – undo
888 888
 		$path = rtrim($path, '/');
889 889
 
890 890
 		if (!is_null($cloudIdPort)) {
891
-			$cloudId = $cloudId . ':' . $cloudIdPort;
891
+			$cloudId = $cloudId.':'.$cloudIdPort;
892 892
 		}
893 893
 
894 894
 		return [$scheme, $cloudId, $path];
Please login to merge, or discard this patch.
lib/Listeners/Files/RemovingMember.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -98,7 +98,7 @@  discard block
 block discarded – undo
98 98
 		$singleIds = array_merge(
99 99
 			[$circle->getSingleId()],
100 100
 			array_map(
101
-				function (Membership $membership) {
101
+				function(Membership $membership) {
102 102
 					return $membership->getCircleId();
103 103
 				}, $circle->getMemberships()
104 104
 			)
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
 			try {
153 153
 				$this->shareWrapperService->deleteUserSharesToCircle($singleId, $member->getUserId());
154 154
 			} catch (\Exception $e) {
155
-				$this->logger->notice('issue while deleting user shares: ' . $e->getMessage());
155
+				$this->logger->notice('issue while deleting user shares: '.$e->getMessage());
156 156
 			}
157 157
 		}
158 158
 	}
Please login to merge, or discard this patch.
lib/Db/EventWrapperRequest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -105,7 +105,7 @@
 block discarded – undo
105 105
 				$qb->exprLimitInt('status', EventWrapper::STATUS_FAILED),
106 106
 				$expr->andX(
107 107
 					$qb->exprLimitInt('status', EventWrapper::STATUS_INIT),
108
-					$qb->exprGt('creation', time() - 86400),  // only freshly created; less than 3 hours
108
+					$qb->exprGt('creation', time() - 86400), // only freshly created; less than 3 hours
109 109
 					$qb->exprLt('creation', time() - 900)     // but not too fresh, at least 15 minutes
110 110
 				)
111 111
 			)
Please login to merge, or discard this patch.
lib/Service/ConfigService.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -244,7 +244,7 @@  discard block
 block discarded – undo
244 244
 			return $value;
245 245
 		}
246 246
 
247
-		if (($value = $this->config->getSystemValue(Application::APP_ID . '.' . $key, '')) !== '') {
247
+		if (($value = $this->config->getSystemValue(Application::APP_ID.'.'.$key, '')) !== '') {
248 248
 			return $value;
249 249
 		}
250 250
 
@@ -498,7 +498,7 @@  discard block
 block discarded – undo
498 498
 	 */
499 499
 	public function getTrustedDomains(): array {
500 500
 		return array_map(
501
-			function (string $address) {
501
+			function(string $address) {
502 502
 				return strtolower($address);
503 503
 			}, $this->config->getSystemValue('trusted_domains', [])
504 504
 		);
@@ -534,7 +534,7 @@  discard block
 block discarded – undo
534 534
 		}
535 535
 
536 536
 		if (array_key_exists('port', $loopback)) {
537
-			$loopbackCloudId = $loopback['host'] . ':' . $loopback['port'];
537
+			$loopbackCloudId = $loopback['host'].':'.$loopback['port'];
538 538
 		} else {
539 539
 			$loopbackCloudId = $loopback['host'];
540 540
 		}
@@ -573,13 +573,13 @@  discard block
 block discarded – undo
573 573
 			$path = $this->getAppValue(self::LOOPBACK_CLOUD_PATH);
574 574
 		}
575 575
 
576
-		$base = $scheme . '://' . $instance . $path;
576
+		$base = $scheme.'://'.$instance.$path;
577 577
 
578 578
 		if ($route === '') {
579 579
 			return $base;
580 580
 		}
581 581
 
582
-		return rtrim($base, '/') . $this->linkToRoute($route, $args);
582
+		return rtrim($base, '/').$this->linkToRoute($route, $args);
583 583
 	}
584 584
 
585 585
 
@@ -684,7 +684,7 @@  discard block
 block discarded – undo
684 684
 	): string {
685 685
 		$name = ($displayName) ? $federatedUser->getDisplayName() : $federatedUser->getUserId();
686 686
 		if ($federatedUser->getUserType() === Member::TYPE_MAIL) {
687
-			return $name . ' ' . $this->displayInstance(
687
+			return $name.' '.$this->displayInstance(
688 688
 				$federatedUser->getInstance(),
689 689
 				self::DISPLAY_PARENTHESIS
690 690
 			);
@@ -694,7 +694,7 @@  discard block
 block discarded – undo
694 694
 			return $name;
695 695
 		}
696 696
 
697
-		return $name . $this->displayInstance($federatedUser->getInstance(), self::DISPLAY_AT);
697
+		return $name.$this->displayInstance($federatedUser->getInstance(), self::DISPLAY_AT);
698 698
 	}
699 699
 
700 700
 	/**
@@ -710,9 +710,9 @@  discard block
 block discarded – undo
710 710
 
711 711
 		switch ($type) {
712 712
 			case self::DISPLAY_AT:
713
-				return '@' . $instance;
713
+				return '@'.$instance;
714 714
 			case self::DISPLAY_PARENTHESIS:
715
-				return '(' . $instance . ')';
715
+				return '('.$instance.')';
716 716
 		}
717 717
 
718 718
 		return $instance;
@@ -764,7 +764,7 @@  discard block
 block discarded – undo
764 764
 			// when running from the occ command, /index.php is not removed by itself
765 765
 			if (str_starts_with($path, '/index.php/')
766 766
 				&& $this->config->getSystemValueString('htaccess.RewriteBase', '') !== '') {
767
-				$path = $this->config->getSystemValueString('htaccess.RewriteBase', '/') . substr($path, 11);
767
+				$path = $this->config->getSystemValueString('htaccess.RewriteBase', '/').substr($path, 11);
768 768
 			}
769 769
 
770 770
 			$knownPath = parse_url($this->config->getSystemValue('overwrite.cli.url'), PHP_URL_PATH);
Please login to merge, or discard this patch.
lib/Command/CirclesRemote.php 1 patch
Spacing   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -173,19 +173,19 @@  discard block
 block discarded – undo
173 173
 
174 174
 		$webfinger = $this->getWebfinger($host, Application::APP_SUBJECT);
175 175
 		if ($this->input->getOption('all')) {
176
-			$this->output->writeln('- Webfinger on <info>' . $host . '</info>');
176
+			$this->output->writeln('- Webfinger on <info>'.$host.'</info>');
177 177
 			$this->output->writeln(json_encode($webfinger, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES));
178 178
 			$this->output->writeln('');
179 179
 		}
180 180
 
181 181
 		if ($this->input->getOption('all')) {
182 182
 			$circleLink = $this->extractLink(Application::APP_REL, $webfinger);
183
-			$this->output->writeln('- Information about Circles app on <info>' . $host . '</info>');
183
+			$this->output->writeln('- Information about Circles app on <info>'.$host.'</info>');
184 184
 			$this->output->writeln(json_encode($circleLink, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES));
185 185
 			$this->output->writeln('');
186 186
 		}
187 187
 
188
-		$this->output->writeln('- Available services on <info>' . $host . '</info>');
188
+		$this->output->writeln('- Available services on <info>'.$host.'</info>');
189 189
 		foreach ($webfinger->getLinks() as $link) {
190 190
 			$app = $link->getProperty('name');
191 191
 			$ver = $link->getProperty('version');
@@ -193,14 +193,14 @@  discard block
 block discarded – undo
193 193
 				$app .= ' ';
194 194
 			}
195 195
 			if ($ver !== '') {
196
-				$ver = 'v' . $ver;
196
+				$ver = 'v'.$ver;
197 197
 			}
198 198
 
199
-			$this->output->writeln(' * ' . $link->getRel() . ' ' . $app . $ver);
199
+			$this->output->writeln(' * '.$link->getRel().' '.$app.$ver);
200 200
 		}
201 201
 		$this->output->writeln('');
202 202
 
203
-		$this->output->writeln('- Resources related to Circles on <info>' . $host . '</info>');
203
+		$this->output->writeln('- Resources related to Circles on <info>'.$host.'</info>');
204 204
 		$resource = $this->getResourceData($host, Application::APP_SUBJECT, Application::APP_REL);
205 205
 		$this->output->writeln(json_encode($resource, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES));
206 206
 		$this->output->writeln('');
@@ -208,7 +208,7 @@  discard block
 block discarded – undo
208 208
 
209 209
 		$tempUid = $resource->g('uid');
210 210
 		$this->output->writeln(
211
-			'- Confirming UID=' . $tempUid . ' from parsed Signatory at <info>' . $host . '</info>'
211
+			'- Confirming UID='.$tempUid.' from parsed Signatory at <info>'.$host.'</info>'
212 212
 		);
213 213
 
214 214
 		try {
@@ -217,15 +217,15 @@  discard block
 block discarded – undo
217 217
 			$this->output->writeln(' * No SignatureException: <info>Identity authed</info>');
218 218
 		} catch (SignatureException $e) {
219 219
 			$this->output->writeln(
220
-				'<error>' . $host . ' cannot auth its identity: ' . $e->getMessage() . '</error>'
220
+				'<error>'.$host.' cannot auth its identity: '.$e->getMessage().'</error>'
221 221
 			);
222 222
 
223 223
 			return;
224 224
 		}
225 225
 
226
-		$this->output->writeln(' * Found <info>' . $remoteSignatory->getUid() . '</info>');
226
+		$this->output->writeln(' * Found <info>'.$remoteSignatory->getUid().'</info>');
227 227
 		if ($remoteSignatory->getUid(true) !== $tempUid) {
228
-			$this->output->writeln('<error>looks like ' . $host . ' is faking its identity');
228
+			$this->output->writeln('<error>looks like '.$host.' is faking its identity');
229 229
 
230 230
 			return;
231 231
 		}
@@ -233,7 +233,7 @@  discard block
 block discarded – undo
233 233
 		$this->output->writeln('');
234 234
 
235 235
 		$testUrl = $resource->g('test');
236
-		$this->output->writeln('- Testing signed payload on <info>' . $testUrl . '</info>');
236
+		$this->output->writeln('- Testing signed payload on <info>'.$testUrl.'</info>');
237 237
 
238 238
 		try {
239 239
 			$localSignatory = $this->remoteStreamService->getAppSignatory();
@@ -255,18 +255,18 @@  discard block
 block discarded – undo
255 255
 		$this->output->writeln('');
256 256
 
257 257
 		$this->output->writeln(' * Clear Signature: ');
258
-		$this->output->writeln('<comment>' . $signedRequest->getClearSignature() . '</comment>');
258
+		$this->output->writeln('<comment>'.$signedRequest->getClearSignature().'</comment>');
259 259
 		$this->output->writeln('');
260 260
 
261 261
 		$this->output->writeln(' * Signed Signature (base64 encoded): ');
262 262
 		$this->output->writeln(
263
-			'<comment>' . base64_encode($signedRequest->getSignedSignature()) . '</comment>'
263
+			'<comment>'.base64_encode($signedRequest->getSignedSignature()).'</comment>'
264 264
 		);
265 265
 		$this->output->writeln('');
266 266
 
267 267
 		$result = $signedRequest->getOutgoingRequest()->getResult();
268 268
 		$code = $result->getStatusCode();
269
-		$this->output->writeln(' * Result: ' . (($code === 200) ? '<info>' . $code . '</info>' : $code));
269
+		$this->output->writeln(' * Result: '.(($code === 200) ? '<info>'.$code.'</info>' : $code));
270 270
 		$this->output->writeln(
271 271
 			json_encode(json_decode($result->getContent(), true), JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES)
272 272
 		);
@@ -288,7 +288,7 @@  discard block
 block discarded – undo
288 288
 				$stored = new RemoteInstance();
289 289
 				$this->remoteStreamService->confirmValidRemote($remoteSignatory, $stored);
290 290
 				$this->output->writeln(
291
-					'<info>The remote instance ' . $host
291
+					'<info>The remote instance '.$host
292 292
 					. ' is already known with this current identity</info>'
293 293
 				);
294 294
 
@@ -298,7 +298,7 @@  discard block
 block discarded – undo
298 298
 
299 299
 				if ($remoteSignatory->getType() !== $stored->getType()) {
300 300
 					$this->output->writeln(
301
-						'- updating type from ' . $stored->getType() . ' to '
301
+						'- updating type from '.$stored->getType().' to '
302 302
 						. $remoteSignatory->getType()
303 303
 					);
304 304
 					$this->remoteStreamService->update(
@@ -308,7 +308,7 @@  discard block
 block discarded – undo
308 308
 
309 309
 				if ($remoteSignatory->getInstance() !== $stored->getInstance()) {
310 310
 					$this->output->writeln(
311
-						'- updating host from ' . $stored->getInstance() . ' to '
311
+						'- updating host from '.$stored->getInstance().' to '
312 312
 						. $remoteSignatory->getInstance()
313 313
 					);
314 314
 					$this->remoteStreamService->update(
@@ -317,7 +317,7 @@  discard block
 block discarded – undo
317 317
 				}
318 318
 				if ($remoteSignatory->getId() !== $stored->getId()) {
319 319
 					$this->output->writeln(
320
-						'- updating href/Id from ' . $stored->getId() . ' to '
320
+						'- updating href/Id from '.$stored->getId().' to '
321 321
 						. $remoteSignatory->getId()
322 322
 					);
323 323
 					$this->remoteStreamService->update($remoteSignatory, RemoteStreamService::UPDATE_HREF);
@@ -341,10 +341,10 @@  discard block
 block discarded – undo
341 341
 		$helper = $this->getHelper('question');
342 342
 
343 343
 		$this->output->writeln(
344
-			'The remote instance <info>' . $remoteSignatory->getInstance() . '</info> looks good.'
344
+			'The remote instance <info>'.$remoteSignatory->getInstance().'</info> looks good.'
345 345
 		);
346 346
 		$question = new ConfirmationQuestion(
347
-			'Would you like to identify this remote instance as \'<comment>' . $remoteSignatory->getType()
347
+			'Would you like to identify this remote instance as \'<comment>'.$remoteSignatory->getType()
348 348
 			. '</comment>\' using interface \'<comment>'
349 349
 			. InterfaceService::$LIST_IFACE[$remoteSignatory->getInterface()]
350 350
 			. '</comment>\' ? (y/N) ',
@@ -372,7 +372,7 @@  discard block
 block discarded – undo
372 372
 		$helper = $this->getHelper('question');
373 373
 
374 374
 		$this->output->writeln(
375
-			'The remote instance <info>' . $remoteSignatory->getInstance()
375
+			'The remote instance <info>'.$remoteSignatory->getInstance()
376 376
 			. '</info> is known but <error>its identity has changed.</error>'
377 377
 		);
378 378
 		$this->output->writeln(
@@ -434,7 +434,7 @@  discard block
 block discarded – undo
434 434
 	private function verifyGSInstances(): void {
435 435
 		$instances = $this->globalScaleService->getGlobalScaleInstances();
436 436
 		$known = array_map(
437
-			function (RemoteInstance $instance): string {
437
+			function(RemoteInstance $instance): string {
438 438
 				return $instance->getInstance();
439 439
 			}, $this->remoteRequest->getFromType(RemoteInstance::TYPE_GLOBALSCALE)
440 440
 		);
@@ -450,7 +450,7 @@  discard block
 block discarded – undo
450 450
 	 * @param string $instance
451 451
 	 */
452 452
 	private function syncGSInstance(string $instance): void {
453
-		$this->output->write('Adding <comment>' . $instance . '</comment>: ');
453
+		$this->output->write('Adding <comment>'.$instance.'</comment>: ');
454 454
 		if ($this->configService->isLocalInstance($instance)) {
455 455
 			$this->output->writeln('<comment>instance is local</comment>');
456 456
 			return;
@@ -465,8 +465,8 @@  discard block
 block discarded – undo
465 465
 			);
466 466
 			$this->output->writeln('<info>ok</info>');
467 467
 		} catch (Exception $e) {
468
-			$msg = ($e->getMessage() === '') ? '' : ' (' . $e->getMessage() . ')';
469
-			$this->output->writeln('<error>' . get_class($e) . $msg . '</error>');
468
+			$msg = ($e->getMessage() === '') ? '' : ' ('.$e->getMessage().')';
469
+			$this->output->writeln('<error>'.get_class($e).$msg.'</error>');
470 470
 		}
471 471
 	}
472 472
 
@@ -484,12 +484,12 @@  discard block
 block discarded – undo
484 484
 			try {
485 485
 				$current = $this->remoteStreamService->retrieveRemoteInstance($instance->getInstance());
486 486
 				if ($current->getUid(true) === $instance->getUid(true)) {
487
-					$currentUid = '<info>' . $current->getUid(true) . '</info>';
487
+					$currentUid = '<info>'.$current->getUid(true).'</info>';
488 488
 				} else {
489
-					$currentUid = '<error>' . $current->getUid(true) . '</error>';
489
+					$currentUid = '<error>'.$current->getUid(true).'</error>';
490 490
 				}
491 491
 			} catch (Exception $e) {
492
-				$currentUid = '<error>' . $e->getMessage() . '</error>';
492
+				$currentUid = '<error>'.$e->getMessage().'</error>';
493 493
 			}
494 494
 
495 495
 			$table->appendRow(
@@ -516,7 +516,7 @@  discard block
 block discarded – undo
516 516
 			}
517 517
 		}
518 518
 
519
-		throw new Exception('Unknown type: ' . implode(', ', RemoteInstance::$LIST_TYPE));
519
+		throw new Exception('Unknown type: '.implode(', ', RemoteInstance::$LIST_TYPE));
520 520
 	}
521 521
 
522 522
 	/**
@@ -529,6 +529,6 @@  discard block
 block discarded – undo
529 529
 			}
530 530
 		}
531 531
 
532
-		throw new Exception('Unknown interface: ' . implode(', ', InterfaceService::$LIST_IFACE));
532
+		throw new Exception('Unknown interface: '.implode(', ', InterfaceService::$LIST_IFACE));
533 533
 	}
534 534
 }
Please login to merge, or discard this patch.
lib/Api/v1/Circles.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -252,7 +252,7 @@
 block discarded – undo
252 252
 			try {
253 253
 				$circleService->getCircle($uniqueId); // checking current user have access to said circle
254 254
 				$files = array_map(
255
-					function (ShareWrapper $wrapper): int {
255
+					function(ShareWrapper $wrapper): int {
256 256
 						return $wrapper->getFileSource();
257 257
 					}, $shareWrapperService->getSharesToCircle($uniqueId)
258 258
 				);
Please login to merge, or discard this patch.
lib/Db/CoreQueryBuilder.php 1 patch
Spacing   +83 added lines, -83 removed lines patch added patch discarded remove patch
@@ -398,8 +398,8 @@  discard block
 block discarded – undo
398 398
 			foreach (explode(' ', $circle->getDisplayName()) as $word) {
399 399
 				$andX->add(
400 400
 					$expr->iLike(
401
-						$this->getDefaultSelectAlias() . '.' . 'display_name',
402
-						$this->createNamedParameter('%' . $word . '%')
401
+						$this->getDefaultSelectAlias().'.'.'display_name',
402
+						$this->createNamedParameter('%'.$word.'%')
403 403
 					)
404 404
 				);
405 405
 			}
@@ -430,7 +430,7 @@  discard block
 block discarded – undo
430 430
 			$this->generateRemoteInstanceSelectAlias($aliasRemoteInstance)
431 431
 				 ->leftJoin(
432 432
 				 	$alias, CoreRequestBuilder::TABLE_REMOTE, $aliasRemoteInstance,
433
-				 	$expr->eq($alias . '.instance', $aliasRemoteInstance . '.instance')
433
+				 	$expr->eq($alias.'.instance', $aliasRemoteInstance.'.instance')
434 434
 				 );
435 435
 		} catch (RequestBuilderException $e) {
436 436
 		}
@@ -482,7 +482,7 @@  discard block
 block discarded – undo
482 482
 		$expr = $this->expr();
483 483
 		$this->leftJoin(
484 484
 			$this->getDefaultSelectAlias(), CoreRequestBuilder::TABLE_REMOTE, $aliasRemote,
485
-			$expr->eq($aliasRemote . '.instance', $this->createNamedParameter($remoteInstance->getInstance()))
485
+			$expr->eq($aliasRemote.'.instance', $this->createNamedParameter($remoteInstance->getInstance()))
486 486
 		);
487 487
 	}
488 488
 
@@ -510,12 +510,12 @@  discard block
 block discarded – undo
510 510
 		$this->leftJoin(
511 511
 			$this->getDefaultSelectAlias(), CoreRequestBuilder::TABLE_MEMBER, $aliasRemoteMember,
512 512
 			$expr->andX(
513
-				$expr->eq($aliasRemoteMember . '.circle_id', $aliasCircle . '.unique_id'),
513
+				$expr->eq($aliasRemoteMember.'.circle_id', $aliasCircle.'.unique_id'),
514 514
 				$expr->eq(
515
-					$aliasRemoteMember . '.instance',
515
+					$aliasRemoteMember.'.instance',
516 516
 					$this->createNamedParameter($remoteInstance->getInstance())
517 517
 				),
518
-				$expr->gte($aliasRemoteMember . '.level', $this->createNamedParameter(Member::LEVEL_MEMBER))
518
+				$expr->gte($aliasRemoteMember.'.level', $this->createNamedParameter(Member::LEVEL_MEMBER))
519 519
 			)
520 520
 		);
521 521
 	}
@@ -547,21 +547,21 @@  discard block
 block discarded – undo
547 547
 		$this->leftJoin(
548 548
 			$this->getDefaultSelectAlias(), CoreRequestBuilder::TABLE_MEMBER, $aliasRemoteCircle,
549 549
 			$expr->andX(
550
-				$expr->eq($aliasRemoteCircle . '.single_id', $aliasCircle . '.unique_id'),
551
-				$expr->emptyString($aliasRemoteCircle . '.instance'),
552
-				$expr->gte($aliasRemoteCircle . '.level', $this->createNamedParameter(Member::LEVEL_MEMBER))
550
+				$expr->eq($aliasRemoteCircle.'.single_id', $aliasCircle.'.unique_id'),
551
+				$expr->emptyString($aliasRemoteCircle.'.instance'),
552
+				$expr->gte($aliasRemoteCircle.'.level', $this->createNamedParameter(Member::LEVEL_MEMBER))
553 553
 			)
554 554
 		);
555 555
 		$this->leftJoin(
556 556
 			$this->getDefaultSelectAlias(), CoreRequestBuilder::TABLE_MEMBER, $aliasRemoteCircleOwner,
557 557
 			$expr->andX(
558
-				$expr->eq($aliasRemoteCircle . '.circle_id', $aliasRemoteCircleOwner . '.circle_id'),
558
+				$expr->eq($aliasRemoteCircle.'.circle_id', $aliasRemoteCircleOwner.'.circle_id'),
559 559
 				$expr->eq(
560
-					$aliasRemoteCircleOwner . '.instance',
560
+					$aliasRemoteCircleOwner.'.instance',
561 561
 					$this->createNamedParameter($remoteInstance->getInstance())
562 562
 				),
563 563
 				$expr->eq(
564
-					$aliasRemoteCircleOwner . '.level', $this->createNamedParameter(Member::LEVEL_OWNER)
564
+					$aliasRemoteCircleOwner.'.level', $this->createNamedParameter(Member::LEVEL_OWNER)
565 565
 				)
566 566
 			)
567 567
 		);
@@ -594,16 +594,16 @@  discard block
 block discarded – undo
594 594
 		$expr = $this->expr();
595 595
 		$orX = $expr->orX();
596 596
 		$orX->add(
597
-			$expr->eq($aliasRemote . '.type', $this->createNamedParameter(RemoteInstance::TYPE_GLOBALSCALE))
597
+			$expr->eq($aliasRemote.'.type', $this->createNamedParameter(RemoteInstance::TYPE_GLOBALSCALE))
598 598
 		);
599 599
 
600 600
 		$orExtOrPassive = $expr->orX();
601 601
 		$orExtOrPassive->add(
602
-			$expr->eq($aliasRemote . '.type', $this->createNamedParameter(RemoteInstance::TYPE_EXTERNAL))
602
+			$expr->eq($aliasRemote.'.type', $this->createNamedParameter(RemoteInstance::TYPE_EXTERNAL))
603 603
 		);
604 604
 		if (!$sensitive) {
605 605
 			$orExtOrPassive->add(
606
-				$expr->eq($aliasRemote . '.type', $this->createNamedParameter(RemoteInstance::TYPE_PASSIVE))
606
+				$expr->eq($aliasRemote.'.type', $this->createNamedParameter(RemoteInstance::TYPE_PASSIVE))
607 607
 			);
608 608
 		} else {
609 609
 			if ($this->getDefaultSelectAlias() === CoreQueryBuilder::MEMBER) {
@@ -612,8 +612,8 @@  discard block
 block discarded – undo
612 612
 		}
613 613
 
614 614
 		$orInstance = $expr->orX();
615
-		$orInstance->add($expr->isNotNull($aliasRemoteMember . '.instance'));
616
-		$orInstance->add($expr->isNotNull($aliasRemoteCircleOwner . '.instance'));
615
+		$orInstance->add($expr->isNotNull($aliasRemoteMember.'.instance'));
616
+		$orInstance->add($expr->isNotNull($aliasRemoteCircleOwner.'.instance'));
617 617
 
618 618
 		$andExternal = $expr->andX();
619 619
 		$andExternal->add($orExtOrPassive);
@@ -622,13 +622,13 @@  discard block
 block discarded – undo
622 622
 		$orExtOrTrusted = $expr->orX();
623 623
 		$orExtOrTrusted->add($andExternal);
624 624
 		$orExtOrTrusted->add(
625
-			$expr->eq($aliasRemote . '.type', $this->createNamedParameter(RemoteInstance::TYPE_TRUSTED))
625
+			$expr->eq($aliasRemote.'.type', $this->createNamedParameter(RemoteInstance::TYPE_TRUSTED))
626 626
 		);
627 627
 
628 628
 		$andTrusted = $expr->andX();
629 629
 		$andTrusted->add($orExtOrTrusted);
630 630
 		$andTrusted->add($this->exprLimitBitwise('config', Circle::CFG_FEDERATED, $aliasCircle));
631
-		$andTrusted->add($expr->emptyString($aliasOwner . '.instance'));
631
+		$andTrusted->add($expr->emptyString($aliasOwner.'.instance'));
632 632
 		$orX->add($andTrusted);
633 633
 
634 634
 		$this->andWhere($orX);
@@ -655,7 +655,7 @@  discard block
 block discarded – undo
655 655
 		}
656 656
 		$this->innerJoin(
657 657
 			$this->getDefaultSelectAlias(), CoreRequestBuilder::TABLE_MEMBER, $aliasMember,
658
-			$expr->eq($aliasMember . '.circle_id', $alias . '.unique_id')
658
+			$expr->eq($aliasMember.'.circle_id', $alias.'.unique_id')
659 659
 		);
660 660
 
661 661
 		$this->filterDirectMembership($aliasMember, $member);
@@ -680,12 +680,12 @@  discard block
 block discarded – undo
680 680
 			$aliasCircle,
681 681
 			'circles_membership',
682 682
 			$aliasMembership,
683
-			$this->expr()->eq($aliasCircle . '.unique_id', $aliasMembership . '.circle_id')
683
+			$this->expr()->eq($aliasCircle.'.unique_id', $aliasMembership.'.circle_id')
684 684
 		);
685 685
 
686 686
 		$this->andWhere(
687 687
 			$this->expr()->eq(
688
-				$aliasMembership . '.single_id',
688
+				$aliasMembership.'.single_id',
689 689
 				$this->createNamedParameter($federatedUser->getSingleId())
690 690
 			)
691 691
 		);
@@ -706,19 +706,19 @@  discard block
 block discarded – undo
706 706
 
707 707
 		if ($member->getUserId() !== '') {
708 708
 			$andX->add(
709
-				$expr->eq($aliasMember . '.user_id', $this->createNamedParameter($member->getUserId()))
709
+				$expr->eq($aliasMember.'.user_id', $this->createNamedParameter($member->getUserId()))
710 710
 			);
711 711
 		}
712 712
 
713 713
 		if ($member->getSingleId() !== '') {
714 714
 			$andX->add(
715
-				$expr->eq($aliasMember . '.single_id', $this->createNamedParameter($member->getSingleId()))
715
+				$expr->eq($aliasMember.'.single_id', $this->createNamedParameter($member->getSingleId()))
716 716
 			);
717 717
 		}
718 718
 
719 719
 		if ($member->getUserType() > 0) {
720 720
 			$andX->add(
721
-				$expr->eq($aliasMember . '.user_type', $this->createNamedParameter($member->getUserType()))
721
+				$expr->eq($aliasMember.'.user_type', $this->createNamedParameter($member->getUserType()))
722 722
 			);
723 723
 		}
724 724
 
@@ -727,7 +727,7 @@  discard block
 block discarded – undo
727 727
 		if ($member->getLevel() > 0) {
728 728
 			$andX->add(
729 729
 				$expr->gte(
730
-					$aliasMember . '.level',
730
+					$aliasMember.'.level',
731 731
 					$this->createNamedParameter($member->getLevel(), IQueryBuilder::PARAM_INT)
732 732
 				)
733 733
 			);
@@ -768,7 +768,7 @@  discard block
 block discarded – undo
768 768
 			$helperAlias,
769 769
 			CoreRequestBuilder::TABLE_CIRCLE,
770 770
 			$aliasCircle,
771
-			$expr->eq($aliasCircle . '.unique_id', $helperAlias . '.' . $field)
771
+			$expr->eq($aliasCircle.'.unique_id', $helperAlias.'.'.$field)
772 772
 		);
773 773
 
774 774
 		if (!is_null($initiator)) {
@@ -799,7 +799,7 @@  discard block
 block discarded – undo
799 799
 		$this->generateCircleSelectAlias($aliasInvitedBy)
800 800
 			 ->leftJoin(
801 801
 			 	$aliasMember, CoreRequestBuilder::TABLE_CIRCLE, $aliasInvitedBy,
802
-			 	$expr->eq($aliasMember . '.invited_by', $aliasInvitedBy . '.unique_id')
802
+			 	$expr->eq($aliasMember.'.invited_by', $aliasInvitedBy.'.unique_id')
803 803
 			 );
804 804
 
805 805
 		$this->leftJoinOwner($aliasInvitedBy);
@@ -830,7 +830,7 @@  discard block
 block discarded – undo
830 830
 		$this->generateCircleSelectAlias($aliasBasedOn)
831 831
 			 ->leftJoin(
832 832
 			 	$aliasMember, CoreRequestBuilder::TABLE_CIRCLE, $aliasBasedOn,
833
-			 	$expr->eq($aliasBasedOn . '.unique_id', $aliasMember . '.single_id')
833
+			 	$expr->eq($aliasBasedOn.'.unique_id', $aliasMember.'.single_id')
834 834
 			 );
835 835
 
836 836
 		if (!is_null($initiator)) {
@@ -863,9 +863,9 @@  discard block
 block discarded – undo
863 863
 			 ->leftJoin(
864 864
 			 	$alias, CoreRequestBuilder::TABLE_MEMBER, $aliasMember,
865 865
 			 	$expr->andX(
866
-			 		$expr->eq($aliasMember . '.circle_id', $alias . '.' . $field),
866
+			 		$expr->eq($aliasMember.'.circle_id', $alias.'.'.$field),
867 867
 			 		$expr->eq(
868
-			 			$aliasMember . '.level',
868
+			 			$aliasMember.'.level',
869 869
 			 			$this->createNamedParameter(Member::LEVEL_OWNER, self::PARAM_INT)
870 870
 			 		)
871 871
 			 	)
@@ -897,7 +897,7 @@  discard block
 block discarded – undo
897 897
 
898 898
 		$expr = $this->expr();
899 899
 
900
-		$on = $expr->andX($expr->eq($aliasMembership . '.circle_id', $alias . '.' . $field));
900
+		$on = $expr->andX($expr->eq($aliasMembership.'.circle_id', $alias.'.'.$field));
901 901
 
902 902
 		// limit on membership level if requested
903 903
 		$minLevel = $probe->getMinimumLevel();
@@ -938,8 +938,8 @@  discard block
 block discarded – undo
938 938
 			 ->leftJoin(
939 939
 			 	$alias, CoreRequestBuilder::TABLE_MEMBER, $aliasMember,
940 940
 			 	$expr->andX(
941
-			 		$expr->eq($aliasMember . '.circle_id', $alias . '.' . $fieldCircleId),
942
-			 		$expr->eq($aliasMember . '.single_id', $alias . '.' . $fieldSingleId),
941
+			 		$expr->eq($aliasMember.'.circle_id', $alias.'.'.$fieldCircleId),
942
+			 		$expr->eq($aliasMember.'.single_id', $alias.'.'.$fieldSingleId),
943 943
 			 		$this->exprGt('level', Member::LEVEL_MEMBER, true, $aliasMember)
944 944
 			 	)
945 945
 			 );
@@ -971,7 +971,7 @@  discard block
 block discarded – undo
971 971
 
972 972
 		$this->leftJoin(
973 973
 			$alias, CoreRequestBuilder::TABLE_MEMBERSHIP, $aliasMembership,
974
-			$expr->eq($aliasMembership . '.circle_id', $alias . '.' . $field)
974
+			$expr->eq($aliasMembership.'.circle_id', $alias.'.'.$field)
975 975
 		);
976 976
 
977 977
 //		if (!$this->getBool('getData', $options, false)) {
@@ -985,8 +985,8 @@  discard block
 block discarded – undo
985 985
 			 ->leftJoin(
986 986
 			 	$alias, CoreRequestBuilder::TABLE_MEMBER, $aliasInheritedBy,
987 987
 			 	$expr->andX(
988
-			 		$expr->eq($aliasMembership . '.inheritance_last', $aliasInheritedBy . '.circle_id'),
989
-			 		$expr->eq($aliasMembership . '.single_id', $aliasInheritedBy . '.single_id')
988
+			 		$expr->eq($aliasMembership.'.inheritance_last', $aliasInheritedBy.'.circle_id'),
989
+			 		$expr->eq($aliasMembership.'.single_id', $aliasInheritedBy.'.single_id')
990 990
 			 	)
991 991
 			 );
992 992
 
@@ -1003,12 +1003,12 @@  discard block
 block discarded – undo
1003 1003
 		$aliasUpstreamMembership = $this->generateAlias($alias, self::UPSTREAM_MEMBERSHIPS, $options);
1004 1004
 		$this->leftJoin(
1005 1005
 			$alias, CoreRequestBuilder::TABLE_MEMBERSHIP, $aliasUpstreamMembership,
1006
-			$expr->eq($aliasUpstreamMembership . '.single_id', $this->createNamedParameter($singleId))
1006
+			$expr->eq($aliasUpstreamMembership.'.single_id', $this->createNamedParameter($singleId))
1007 1007
 		);
1008 1008
 
1009 1009
 		$orX = $expr->orX(
1010
-			$expr->eq($aliasUpstreamMembership . '.circle_id', $alias . '.' . $field),
1011
-			$expr->eq($alias . '.' . $field, $this->createNamedParameter($singleId))
1010
+			$expr->eq($aliasUpstreamMembership.'.circle_id', $alias.'.'.$field),
1011
+			$expr->eq($alias.'.'.$field, $this->createNamedParameter($singleId))
1012 1012
 		);
1013 1013
 
1014 1014
 		$this->andWhere($orX);
@@ -1029,11 +1029,11 @@  discard block
 block discarded – undo
1029 1029
 
1030 1030
 		$expr = $this->expr();
1031 1031
 		$aliasMembership = $this->generateAlias($alias, self::MEMBERSHIPS);
1032
-		$this->andWhere($expr->eq($aliasMembership . '.circle_id', $this->createNamedParameter($singleId)));
1032
+		$this->andWhere($expr->eq($aliasMembership.'.circle_id', $this->createNamedParameter($singleId)));
1033 1033
 		if ($level > 1) {
1034 1034
 			$this->andWhere(
1035 1035
 				$expr->gte(
1036
-					$aliasMembership . '.level',
1036
+					$aliasMembership.'.level',
1037 1037
 					$this->createNamedParameter($level, IQueryBuilder::PARAM_INT)
1038 1038
 				)
1039 1039
 			);
@@ -1061,8 +1061,8 @@  discard block
 block discarded – undo
1061 1061
 		$this->leftJoin(
1062 1062
 			$alias, CoreRequestBuilder::TABLE_MEMBERSHIP, $aliasMembership,
1063 1063
 			$expr->andX(
1064
-				$expr->eq($aliasMembership . '.inheritance_last', $alias . '.' . $field),
1065
-				$expr->eq($aliasMembership . '.single_id', $alias . '.single_id')
1064
+				$expr->eq($aliasMembership.'.inheritance_last', $alias.'.'.$field),
1065
+				$expr->eq($aliasMembership.'.single_id', $alias.'.single_id')
1066 1066
 			)
1067 1067
 		);
1068 1068
 
@@ -1075,8 +1075,8 @@  discard block
 block discarded – undo
1075 1075
 			 ->leftJoin(
1076 1076
 			 	$aliasMembership, CoreRequestBuilder::TABLE_MEMBER, $aliasInheritanceFrom,
1077 1077
 			 	$expr->andX(
1078
-			 		$expr->eq($aliasMembership . '.circle_id', $aliasInheritanceFrom . '.circle_id'),
1079
-			 		$expr->eq($aliasMembership . '.inheritance_first', $aliasInheritanceFrom . '.single_id')
1078
+			 		$expr->eq($aliasMembership.'.circle_id', $aliasInheritanceFrom.'.circle_id'),
1079
+			 		$expr->eq($aliasMembership.'.inheritance_first', $aliasInheritanceFrom.'.single_id')
1080 1080
 			 	)
1081 1081
 			 );
1082 1082
 	}
@@ -1116,7 +1116,7 @@  discard block
 block discarded – undo
1116 1116
 
1117 1117
 		$this->leftJoin(
1118 1118
 			$alias, CoreRequestBuilder::TABLE_TOKEN, $aliasShareToken,
1119
-			$expr->eq($aliasShareToken . '.share_id', $alias . '.' . $field)
1119
+			$expr->eq($aliasShareToken.'.share_id', $alias.'.'.$field)
1120 1120
 		);
1121 1121
 	}
1122 1122
 
@@ -1158,14 +1158,14 @@  discard block
 block discarded – undo
1158 1158
 		try {
1159 1159
 			$aliasConfig = $this->generateAlias($alias, self::CONFIG, $options);
1160 1160
 			$this->selectAlias(
1161
-				$aliasConfig . '.config',
1162
-				(($alias !== $this->getDefaultSelectAlias()) ? $alias . '_' : '') . 'circle_config'
1161
+				$aliasConfig.'.config',
1162
+				(($alias !== $this->getDefaultSelectAlias()) ? $alias.'_' : '').'circle_config'
1163 1163
 			);
1164 1164
 			$this->leftJoin(
1165 1165
 				$alias,
1166 1166
 				CoreRequestBuilder::TABLE_CIRCLE,
1167 1167
 				$aliasConfig,
1168
-				$expr->eq($alias . '.circle_id', $aliasConfig . '.unique_id')
1168
+				$expr->eq($alias.'.circle_id', $aliasConfig.'.unique_id')
1169 1169
 			);
1170 1170
 		} catch (RequestBuilderException $e) {
1171 1171
 		}
@@ -1203,7 +1203,7 @@  discard block
 block discarded – undo
1203 1203
 			$aliasMembership,
1204 1204
 			$expr->andX(
1205 1205
 				$this->exprLimit('single_id', $initiator->getSingleId(), $aliasMembership),
1206
-				$expr->eq($aliasMembership . '.circle_id', $helperAlias . '.' . $field)
1206
+				$expr->eq($aliasMembership.'.circle_id', $helperAlias.'.'.$field)
1207 1207
 			)
1208 1208
 		);
1209 1209
 
@@ -1222,11 +1222,11 @@  discard block
 block discarded – undo
1222 1222
 			$aliasMembershipCircle = $this->generateAlias($aliasMembership, self::CONFIG, $options);
1223 1223
 			$orXMembershipCircle = $expr->orX();
1224 1224
 			array_map(
1225
-				function (string $alias) use ($orXMembershipCircle, $aliasMembershipCircle) {
1225
+				function(string $alias) use ($orXMembershipCircle, $aliasMembershipCircle) {
1226 1226
 					$orXMembershipCircle->add(
1227 1227
 						$this->expr()->eq(
1228
-							$alias . '.circle_id',
1229
-							$aliasMembershipCircle . '.unique_id'
1228
+							$alias.'.circle_id',
1229
+							$aliasMembershipCircle.'.unique_id'
1230 1230
 						)
1231 1231
 					);
1232 1232
 				},
@@ -1258,7 +1258,7 @@  discard block
 block discarded – undo
1258 1258
 					 	$aliasDirectInitiator,
1259 1259
 					 	$expr->andX(
1260 1260
 					 		$this->exprLimit('single_id', $initiator->getSingleId(), $aliasDirectInitiator),
1261
-					 		$expr->eq($aliasDirectInitiator . '.circle_id', $helperAlias . '.' . $field)
1261
+					 		$expr->eq($aliasDirectInitiator.'.circle_id', $helperAlias.'.'.$field)
1262 1262
 					 	)
1263 1263
 					 );
1264 1264
 			} catch (RequestBuilderException $e) {
@@ -1272,8 +1272,8 @@  discard block
 block discarded – undo
1272 1272
 			$this->leftJoin(
1273 1273
 				$aliasMembership, CoreRequestBuilder::TABLE_MEMBER, $aliasInitiator,
1274 1274
 				$expr->andX(
1275
-					$expr->eq($aliasMembership . '.inheritance_first', $aliasInitiator . '.single_id'),
1276
-					$expr->eq($aliasMembership . '.circle_id', $aliasInitiator . '.circle_id')
1275
+					$expr->eq($aliasMembership.'.inheritance_first', $aliasInitiator.'.single_id'),
1276
+					$expr->eq($aliasMembership.'.circle_id', $aliasInitiator.'.circle_id')
1277 1277
 				)
1278 1278
 			);
1279 1279
 
@@ -1281,8 +1281,8 @@  discard block
 block discarded – undo
1281 1281
 			$this->leftJoin(
1282 1282
 				$aliasInitiator, CoreRequestBuilder::TABLE_MEMBER, $aliasInheritedBy,
1283 1283
 				$expr->andX(
1284
-					$expr->eq($aliasMembership . '.single_id', $aliasInheritedBy . '.single_id'),
1285
-					$expr->eq($aliasMembership . '.inheritance_last', $aliasInheritedBy . '.circle_id')
1284
+					$expr->eq($aliasMembership.'.single_id', $aliasInheritedBy.'.single_id'),
1285
+					$expr->eq($aliasMembership.'.inheritance_last', $aliasInheritedBy.'.circle_id')
1286 1286
 				)
1287 1287
 			);
1288 1288
 
@@ -1327,7 +1327,7 @@  discard block
 block discarded – undo
1327 1327
 			 ->leftJoin(
1328 1328
 			 	$alias, CoreRequestBuilder::TABLE_MEMBER, $aliasInitiator,
1329 1329
 			 	$expr->andX(
1330
-			 		$expr->eq($aliasInitiator . '.circle_id', $helperAlias . '.' . $field),
1330
+			 		$expr->eq($aliasInitiator.'.circle_id', $helperAlias.'.'.$field),
1331 1331
 			 		$this->exprLimitInt('level', Member::LEVEL_OWNER, $aliasInitiator)
1332 1332
 			 	)
1333 1333
 			 );
@@ -1363,7 +1363,7 @@  discard block
 block discarded – undo
1363 1363
 			$orX->add(
1364 1364
 				$expr->andX(
1365 1365
 					$this->exprLimitBitwise('config', Circle::CFG_PERSONAL, $aliasMembershipCircle),
1366
-					$expr->eq($aliasMembership . '.level', $this->createNamedParameter(Member::LEVEL_OWNER))
1366
+					$expr->eq($aliasMembership.'.level', $this->createNamedParameter(Member::LEVEL_OWNER))
1367 1367
 				)
1368 1368
 			);
1369 1369
 		}
@@ -1373,10 +1373,10 @@  discard block
 block discarded – undo
1373 1373
 		$orXLevelCheck = $expr->orX();
1374 1374
 
1375 1375
 		array_map(
1376
-			function (string $alias) use ($orXLevelCheck, $minimumLevel) {
1376
+			function(string $alias) use ($orXLevelCheck, $minimumLevel) {
1377 1377
 				$orXLevelCheck->add(
1378 1378
 					$this->expr()->gte(
1379
-						$alias . '.level',
1379
+						$alias.'.level',
1380 1380
 						$this->createNamedParameter($minimumLevel, self::PARAM_INT)
1381 1381
 					)
1382 1382
 				);
@@ -1466,21 +1466,21 @@  discard block
 block discarded – undo
1466 1466
 		$expr = $this->expr();
1467 1467
 		$andPassive = $expr->andX();
1468 1468
 		$andPassive->add(
1469
-			$expr->eq($alias . '.type', $this->createNamedParameter(RemoteInstance::TYPE_PASSIVE))
1469
+			$expr->eq($alias.'.type', $this->createNamedParameter(RemoteInstance::TYPE_PASSIVE))
1470 1470
 		);
1471 1471
 
1472 1472
 		$orMemberOrLevel = $expr->orX();
1473 1473
 		$orMemberOrLevel->add(
1474
-			$expr->eq($this->getDefaultSelectAlias() . '.instance', $alias . '.instance')
1474
+			$expr->eq($this->getDefaultSelectAlias().'.instance', $alias.'.instance')
1475 1475
 		);
1476 1476
 		// TODO: do we need this ? (display members from the local instance)
1477 1477
 		$orMemberOrLevel->add(
1478
-			$expr->emptyString($this->getDefaultSelectAlias() . '.instance')
1478
+			$expr->emptyString($this->getDefaultSelectAlias().'.instance')
1479 1479
 		);
1480 1480
 
1481 1481
 		$orMemberOrLevel->add(
1482 1482
 			$expr->eq(
1483
-				$this->getDefaultSelectAlias() . '.level',
1483
+				$this->getDefaultSelectAlias().'.level',
1484 1484
 				$this->createNamedParameter(Member::LEVEL_OWNER)
1485 1485
 			)
1486 1486
 		);
@@ -1517,11 +1517,11 @@  discard block
 block discarded – undo
1517 1517
 			 )
1518 1518
 			 ->leftJoin(
1519 1519
 			 	$aliasShare, CoreRequestBuilder::TABLE_FILE_CACHE, $aliasFileCache,
1520
-			 	$expr->eq($aliasShare . '.file_source', $aliasFileCache . '.fileid')
1520
+			 	$expr->eq($aliasShare.'.file_source', $aliasFileCache.'.fileid')
1521 1521
 			 )
1522 1522
 			 ->leftJoin(
1523 1523
 			 	$aliasFileCache, CoreRequestBuilder::TABLE_STORAGES, $aliasStorages,
1524
-			 	$expr->eq($aliasFileCache . '.storage', $aliasStorages . '.numeric_id')
1524
+			 	$expr->eq($aliasFileCache.'.storage', $aliasStorages.'.numeric_id')
1525 1525
 			 );
1526 1526
 	}
1527 1527
 
@@ -1543,8 +1543,8 @@  discard block
 block discarded – undo
1543 1543
 		$this->leftJoin(
1544 1544
 			$aliasShareMemberships, CoreRequestBuilder::TABLE_SHARE, $aliasShareChild,
1545 1545
 			$expr->andX(
1546
-				$expr->eq($aliasShareChild . '.parent', $aliasShare . '.id'),
1547
-				$expr->eq($aliasShareChild . '.share_with', $aliasShareMemberships . '.single_id')
1546
+				$expr->eq($aliasShareChild.'.parent', $aliasShare.'.id'),
1547
+				$expr->eq($aliasShareChild.'.share_with', $aliasShareMemberships.'.single_id')
1548 1548
 			)
1549 1549
 		);
1550 1550
 
@@ -1594,13 +1594,13 @@  discard block
 block discarded – undo
1594 1594
 		$this->leftJoin(
1595 1595
 			$aliasMountMemberships, CoreRequestBuilder::TABLE_MOUNTPOINT, $aliasMountpoint,
1596 1596
 			$expr->andX(
1597
-				$expr->eq($aliasMountpoint . '.mount_id', $aliasMount . '.mount_id'),
1598
-				$expr->eq($aliasMountpoint . '.single_id', $aliasMountMemberships . '.single_id')
1597
+				$expr->eq($aliasMountpoint.'.mount_id', $aliasMount.'.mount_id'),
1598
+				$expr->eq($aliasMountpoint.'.single_id', $aliasMountMemberships.'.single_id')
1599 1599
 			)
1600 1600
 		);
1601 1601
 
1602
-		$this->selectAlias($aliasMountpoint . '.mountpoint', $aliasMountpoint . '_mountpoint');
1603
-		$this->selectAlias($aliasMountpoint . '.mountpoint_hash', $aliasMountpoint . '_mountpoint_hash');
1602
+		$this->selectAlias($aliasMountpoint.'.mountpoint', $aliasMountpoint.'_mountpoint');
1603
+		$this->selectAlias($aliasMountpoint.'.mountpoint_hash', $aliasMountpoint.'_mountpoint_hash');
1604 1604
 	}
1605 1605
 
1606 1606
 
@@ -1708,10 +1708,10 @@  discard block
 block discarded – undo
1708 1708
 	 */
1709 1709
 	public function generateAlias(string $base, string $extension, ?array &$options = []): string {
1710 1710
 		$search = str_replace('_', '.', $base);
1711
-		$path = $search . '.' . $extension;
1711
+		$path = $search.'.'.$extension;
1712 1712
 		if (!$this->validKey($path, $this->getSqlPath())
1713 1713
 			&& !in_array($extension, $this->getArray($search, $this->getSqlPath()))) {
1714
-			throw new RequestBuilderException($extension . ' not found in ' . $search);
1714
+			throw new RequestBuilderException($extension.' not found in '.$search);
1715 1715
 		}
1716 1716
 
1717 1717
 		if (!is_array($options)) {
@@ -1720,15 +1720,15 @@  discard block
 block discarded – undo
1720 1720
 
1721 1721
 		$optionPath = '';
1722 1722
 		foreach (explode('.', $path) as $p) {
1723
-			$optionPath = trim($optionPath . '.' . $p, '.');
1723
+			$optionPath = trim($optionPath.'.'.$p, '.');
1724 1724
 			$options = array_merge(
1725 1725
 				$options,
1726
-				$this->getArray($optionPath . '.' . self::OPTIONS, $this->getSqlPath()),
1727
-				$this->getArray($optionPath . '.' . self::OPTIONS, $this->options)
1726
+				$this->getArray($optionPath.'.'.self::OPTIONS, $this->getSqlPath()),
1727
+				$this->getArray($optionPath.'.'.self::OPTIONS, $this->options)
1728 1728
 			);
1729 1729
 		}
1730 1730
 
1731
-		return $base . '_' . $extension;
1731
+		return $base.'_'.$extension;
1732 1732
 	}
1733 1733
 
1734 1734
 
@@ -1748,7 +1748,7 @@  discard block
 block discarded – undo
1748 1748
 			} else {
1749 1749
 				$k = $arr;
1750 1750
 			}
1751
-			$path[$k] = $prefix . '_' . $k . '_';
1751
+			$path[$k] = $prefix.'_'.$k.'_';
1752 1752
 		}
1753 1753
 
1754 1754
 		return $path;
Please login to merge, or discard this patch.
lib/AppInfo/Application.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -168,7 +168,7 @@
 block discarded – undo
168 168
 	public function registerFilesNavigation() {
169 169
 		$appManager = FilesApp::getNavigationManager();
170 170
 		$appManager->add(
171
-			function () {
171
+			function() {
172 172
 				$l = OC::$server->getL10N('circles');
173 173
 
174 174
 				return [
Please login to merge, or discard this patch.
lib/Model/FileCacheWrapper.php 1 patch
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -456,7 +456,7 @@  discard block
 block discarded – undo
456 456
 		}
457 457
 
458 458
 		$path = $this->getPath();
459
-		[$storageType,] = explode('::', $this->getStorage(), 2);
459
+		[$storageType, ] = explode('::', $this->getStorage(), 2);
460 460
 
461 461
 		if ($path === '') {
462 462
 			// we only accept empty path on external storage
@@ -508,29 +508,29 @@  discard block
 block discarded – undo
508 508
 	 * @throws FileCacheNotFoundException
509 509
 	 */
510 510
 	public function importFromDatabase(array $data, string $prefix = ''): IQueryRow {
511
-		if ($this->getInt($prefix . 'fileid', $data) === 0) {
511
+		if ($this->getInt($prefix.'fileid', $data) === 0) {
512 512
 			throw new FileCacheNotFoundException();
513 513
 		}
514 514
 
515
-		$this->setId($this->getInt($prefix . 'fileid', $data));
516
-		$this->setPath($this->get($prefix . 'path', $data));
517
-		$this->setPermissions($this->getInt($prefix . 'permissions', $data));
518
-		$this->setStorageId($this->getInt($prefix . 'storage', $data));
519
-		$this->setPathHash($this->get($prefix . 'path_hash', $data));
520
-		$this->setParent($this->getInt($prefix . 'parent', $data));
521
-		$this->setName($this->get($prefix . 'name', $data));
522
-		$this->setMimeType($this->getInt($prefix . 'mimetype', $data));
523
-		$this->setMimePart($this->getInt($prefix . 'mimepart', $data));
524
-		$this->setSize($this->getInt($prefix . 'size', $data));
525
-		$this->setMTime($this->getInt($prefix . 'mtime', $data));
526
-		$this->setStorageMTime($this->getInt($prefix . 'storage_mtime', $data));
527
-		$this->setEncrypted($this->getBool($prefix . 'encrypted', $data));
528
-		$this->setUnencryptedSize($this->getInt($prefix . 'unencrypted_size', $data));
529
-		$this->setEtag($this->get($prefix . 'etag', $data));
530
-		$this->setChecksum($this->get($prefix . 'checksum', $data));
515
+		$this->setId($this->getInt($prefix.'fileid', $data));
516
+		$this->setPath($this->get($prefix.'path', $data));
517
+		$this->setPermissions($this->getInt($prefix.'permissions', $data));
518
+		$this->setStorageId($this->getInt($prefix.'storage', $data));
519
+		$this->setPathHash($this->get($prefix.'path_hash', $data));
520
+		$this->setParent($this->getInt($prefix.'parent', $data));
521
+		$this->setName($this->get($prefix.'name', $data));
522
+		$this->setMimeType($this->getInt($prefix.'mimetype', $data));
523
+		$this->setMimePart($this->getInt($prefix.'mimepart', $data));
524
+		$this->setSize($this->getInt($prefix.'size', $data));
525
+		$this->setMTime($this->getInt($prefix.'mtime', $data));
526
+		$this->setStorageMTime($this->getInt($prefix.'storage_mtime', $data));
527
+		$this->setEncrypted($this->getBool($prefix.'encrypted', $data));
528
+		$this->setUnencryptedSize($this->getInt($prefix.'unencrypted_size', $data));
529
+		$this->setEtag($this->get($prefix.'etag', $data));
530
+		$this->setChecksum($this->get($prefix.'checksum', $data));
531 531
 
532 532
 		// small hack as there is no reason to call a recursive method for a single entry from the table
533
-		$this->setStorage($this->get($prefix . CoreQueryBuilder::STORAGES . '_id', $data));
533
+		$this->setStorage($this->get($prefix.CoreQueryBuilder::STORAGES.'_id', $data));
534 534
 
535 535
 		return $this;
536 536
 	}
Please login to merge, or discard this patch.