Passed
Push — master ( f8a4e0...54e3be )
by Christoph
24:32 queued 12:15
created
lib/private/Server.php 1 patch
Spacing   +97 added lines, -97 removed lines patch added patch discarded remove patch
@@ -264,10 +264,10 @@  discard block
 block discarded – undo
264 264
 		$this->registerParameter('isCLI', \OC::$CLI);
265 265
 		$this->registerParameter('serverRoot', \OC::$SERVERROOT);
266 266
 
267
-		$this->registerService(ContainerInterface::class, function (ContainerInterface $c) {
267
+		$this->registerService(ContainerInterface::class, function(ContainerInterface $c) {
268 268
 			return $c;
269 269
 		});
270
-		$this->registerService(\OCP\IServerContainer::class, function (ContainerInterface $c) {
270
+		$this->registerService(\OCP\IServerContainer::class, function(ContainerInterface $c) {
271 271
 			return $c;
272 272
 		});
273 273
 
@@ -291,11 +291,11 @@  discard block
 block discarded – undo
291 291
 
292 292
 		$this->registerAlias(IActionFactory::class, ActionFactory::class);
293 293
 
294
-		$this->registerService(View::class, function (Server $c) {
294
+		$this->registerService(View::class, function(Server $c) {
295 295
 			return new View();
296 296
 		}, false);
297 297
 
298
-		$this->registerService(IPreview::class, function (ContainerInterface $c) {
298
+		$this->registerService(IPreview::class, function(ContainerInterface $c) {
299 299
 			return new PreviewManager(
300 300
 				$c->get(\OCP\IConfig::class),
301 301
 				$c->get(IRootFolder::class),
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
 		/** @deprecated 19.0.0 */
312 312
 		$this->registerDeprecatedAlias('PreviewManager', IPreview::class);
313 313
 
314
-		$this->registerService(\OC\Preview\Watcher::class, function (ContainerInterface $c) {
314
+		$this->registerService(\OC\Preview\Watcher::class, function(ContainerInterface $c) {
315 315
 			return new \OC\Preview\Watcher(
316 316
 				new \OC\Preview\Storage\Root(
317 317
 					$c->get(IRootFolder::class),
@@ -320,7 +320,7 @@  discard block
 block discarded – undo
320 320
 			);
321 321
 		});
322 322
 
323
-		$this->registerService(\OCP\Encryption\IManager::class, function (Server $c) {
323
+		$this->registerService(\OCP\Encryption\IManager::class, function(Server $c) {
324 324
 			$view = new View();
325 325
 			$util = new Encryption\Util(
326 326
 				$view,
@@ -342,7 +342,7 @@  discard block
 block discarded – undo
342 342
 
343 343
 		/** @deprecated 21.0.0 */
344 344
 		$this->registerDeprecatedAlias('EncryptionFileHelper', IFile::class);
345
-		$this->registerService(IFile::class, function (ContainerInterface $c) {
345
+		$this->registerService(IFile::class, function(ContainerInterface $c) {
346 346
 			$util = new Encryption\Util(
347 347
 				new View(),
348 348
 				$c->get(IUserManager::class),
@@ -358,7 +358,7 @@  discard block
 block discarded – undo
358 358
 
359 359
 		/** @deprecated 21.0.0 */
360 360
 		$this->registerDeprecatedAlias('EncryptionKeyStorage', IStorage::class);
361
-		$this->registerService(IStorage::class, function (ContainerInterface $c) {
361
+		$this->registerService(IStorage::class, function(ContainerInterface $c) {
362 362
 			$view = new View();
363 363
 			$util = new Encryption\Util(
364 364
 				$view,
@@ -381,22 +381,22 @@  discard block
 block discarded – undo
381 381
 		/** @deprecated 19.0.0 */
382 382
 		$this->registerDeprecatedAlias('TagManager', \OCP\ITagManager::class);
383 383
 
384
-		$this->registerService('SystemTagManagerFactory', function (ContainerInterface $c) {
384
+		$this->registerService('SystemTagManagerFactory', function(ContainerInterface $c) {
385 385
 			/** @var \OCP\IConfig $config */
386 386
 			$config = $c->get(\OCP\IConfig::class);
387 387
 			$factoryClass = $config->getSystemValue('systemtags.managerFactory', SystemTagManagerFactory::class);
388 388
 			return new $factoryClass($this);
389 389
 		});
390
-		$this->registerService(ISystemTagManager::class, function (ContainerInterface $c) {
390
+		$this->registerService(ISystemTagManager::class, function(ContainerInterface $c) {
391 391
 			return $c->get('SystemTagManagerFactory')->getManager();
392 392
 		});
393 393
 		/** @deprecated 19.0.0 */
394 394
 		$this->registerDeprecatedAlias('SystemTagManager', ISystemTagManager::class);
395 395
 
396
-		$this->registerService(ISystemTagObjectMapper::class, function (ContainerInterface $c) {
396
+		$this->registerService(ISystemTagObjectMapper::class, function(ContainerInterface $c) {
397 397
 			return $c->get('SystemTagManagerFactory')->getObjectMapper();
398 398
 		});
399
-		$this->registerService('RootFolder', function (ContainerInterface $c) {
399
+		$this->registerService('RootFolder', function(ContainerInterface $c) {
400 400
 			$manager = \OC\Files\Filesystem::getMountManager(null);
401 401
 			$view = new View();
402 402
 			$root = new Root(
@@ -416,7 +416,7 @@  discard block
 block discarded – undo
416 416
 
417 417
 			return $root;
418 418
 		});
419
-		$this->registerService(HookConnector::class, function (ContainerInterface $c) {
419
+		$this->registerService(HookConnector::class, function(ContainerInterface $c) {
420 420
 			return new HookConnector(
421 421
 				$c->get(IRootFolder::class),
422 422
 				new View(),
@@ -428,8 +428,8 @@  discard block
 block discarded – undo
428 428
 		/** @deprecated 19.0.0 */
429 429
 		$this->registerDeprecatedAlias('SystemTagObjectMapper', ISystemTagObjectMapper::class);
430 430
 
431
-		$this->registerService(IRootFolder::class, function (ContainerInterface $c) {
432
-			return new LazyRoot(function () use ($c) {
431
+		$this->registerService(IRootFolder::class, function(ContainerInterface $c) {
432
+			return new LazyRoot(function() use ($c) {
433 433
 				return $c->get('RootFolder');
434 434
 			});
435 435
 		});
@@ -440,44 +440,44 @@  discard block
 block discarded – undo
440 440
 		$this->registerDeprecatedAlias('UserManager', \OC\User\Manager::class);
441 441
 		$this->registerAlias(\OCP\IUserManager::class, \OC\User\Manager::class);
442 442
 
443
-		$this->registerService(\OCP\IGroupManager::class, function (ContainerInterface $c) {
443
+		$this->registerService(\OCP\IGroupManager::class, function(ContainerInterface $c) {
444 444
 			$groupManager = new \OC\Group\Manager($this->get(IUserManager::class), $c->get(SymfonyAdapter::class), $this->get(ILogger::class));
445
-			$groupManager->listen('\OC\Group', 'preCreate', function ($gid) {
445
+			$groupManager->listen('\OC\Group', 'preCreate', function($gid) {
446 446
 				/** @var IEventDispatcher $dispatcher */
447 447
 				$dispatcher = $this->get(IEventDispatcher::class);
448 448
 				$dispatcher->dispatchTyped(new BeforeGroupCreatedEvent($gid));
449 449
 			});
450
-			$groupManager->listen('\OC\Group', 'postCreate', function (\OC\Group\Group $group) {
450
+			$groupManager->listen('\OC\Group', 'postCreate', function(\OC\Group\Group $group) {
451 451
 				/** @var IEventDispatcher $dispatcher */
452 452
 				$dispatcher = $this->get(IEventDispatcher::class);
453 453
 				$dispatcher->dispatchTyped(new GroupCreatedEvent($group));
454 454
 			});
455
-			$groupManager->listen('\OC\Group', 'preDelete', function (\OC\Group\Group $group) {
455
+			$groupManager->listen('\OC\Group', 'preDelete', function(\OC\Group\Group $group) {
456 456
 				/** @var IEventDispatcher $dispatcher */
457 457
 				$dispatcher = $this->get(IEventDispatcher::class);
458 458
 				$dispatcher->dispatchTyped(new BeforeGroupDeletedEvent($group));
459 459
 			});
460
-			$groupManager->listen('\OC\Group', 'postDelete', function (\OC\Group\Group $group) {
460
+			$groupManager->listen('\OC\Group', 'postDelete', function(\OC\Group\Group $group) {
461 461
 				/** @var IEventDispatcher $dispatcher */
462 462
 				$dispatcher = $this->get(IEventDispatcher::class);
463 463
 				$dispatcher->dispatchTyped(new GroupDeletedEvent($group));
464 464
 			});
465
-			$groupManager->listen('\OC\Group', 'preAddUser', function (\OC\Group\Group $group, \OC\User\User $user) {
465
+			$groupManager->listen('\OC\Group', 'preAddUser', function(\OC\Group\Group $group, \OC\User\User $user) {
466 466
 				/** @var IEventDispatcher $dispatcher */
467 467
 				$dispatcher = $this->get(IEventDispatcher::class);
468 468
 				$dispatcher->dispatchTyped(new BeforeUserAddedEvent($group, $user));
469 469
 			});
470
-			$groupManager->listen('\OC\Group', 'postAddUser', function (\OC\Group\Group $group, \OC\User\User $user) {
470
+			$groupManager->listen('\OC\Group', 'postAddUser', function(\OC\Group\Group $group, \OC\User\User $user) {
471 471
 				/** @var IEventDispatcher $dispatcher */
472 472
 				$dispatcher = $this->get(IEventDispatcher::class);
473 473
 				$dispatcher->dispatchTyped(new UserAddedEvent($group, $user));
474 474
 			});
475
-			$groupManager->listen('\OC\Group', 'preRemoveUser', function (\OC\Group\Group $group, \OC\User\User $user) {
475
+			$groupManager->listen('\OC\Group', 'preRemoveUser', function(\OC\Group\Group $group, \OC\User\User $user) {
476 476
 				/** @var IEventDispatcher $dispatcher */
477 477
 				$dispatcher = $this->get(IEventDispatcher::class);
478 478
 				$dispatcher->dispatchTyped(new BeforeUserRemovedEvent($group, $user));
479 479
 			});
480
-			$groupManager->listen('\OC\Group', 'postRemoveUser', function (\OC\Group\Group $group, \OC\User\User $user) {
480
+			$groupManager->listen('\OC\Group', 'postRemoveUser', function(\OC\Group\Group $group, \OC\User\User $user) {
481 481
 				/** @var IEventDispatcher $dispatcher */
482 482
 				$dispatcher = $this->get(IEventDispatcher::class);
483 483
 				$dispatcher->dispatchTyped(new UserRemovedEvent($group, $user));
@@ -487,7 +487,7 @@  discard block
 block discarded – undo
487 487
 		/** @deprecated 19.0.0 */
488 488
 		$this->registerDeprecatedAlias('GroupManager', \OCP\IGroupManager::class);
489 489
 
490
-		$this->registerService(Store::class, function (ContainerInterface $c) {
490
+		$this->registerService(Store::class, function(ContainerInterface $c) {
491 491
 			$session = $c->get(ISession::class);
492 492
 			if (\OC::$server->get(SystemConfig::class)->getValue('installed', false)) {
493 493
 				$tokenProvider = $c->get(IProvider::class);
@@ -500,7 +500,7 @@  discard block
 block discarded – undo
500 500
 		$this->registerAlias(IStore::class, Store::class);
501 501
 		$this->registerAlias(IProvider::class, Authentication\Token\Manager::class);
502 502
 
503
-		$this->registerService(\OC\User\Session::class, function (Server $c) {
503
+		$this->registerService(\OC\User\Session::class, function(Server $c) {
504 504
 			$manager = $c->get(IUserManager::class);
505 505
 			$session = new \OC\Session\Memory('');
506 506
 			$timeFactory = new TimeFactory();
@@ -526,26 +526,26 @@  discard block
 block discarded – undo
526 526
 				$c->get(IEventDispatcher::class)
527 527
 			);
528 528
 			/** @deprecated 21.0.0 use BeforeUserCreatedEvent event with the IEventDispatcher instead */
529
-			$userSession->listen('\OC\User', 'preCreateUser', function ($uid, $password) {
529
+			$userSession->listen('\OC\User', 'preCreateUser', function($uid, $password) {
530 530
 				\OC_Hook::emit('OC_User', 'pre_createUser', ['run' => true, 'uid' => $uid, 'password' => $password]);
531 531
 			});
532 532
 			/** @deprecated 21.0.0 use UserCreatedEvent event with the IEventDispatcher instead */
533
-			$userSession->listen('\OC\User', 'postCreateUser', function ($user, $password) {
533
+			$userSession->listen('\OC\User', 'postCreateUser', function($user, $password) {
534 534
 				/** @var \OC\User\User $user */
535 535
 				\OC_Hook::emit('OC_User', 'post_createUser', ['uid' => $user->getUID(), 'password' => $password]);
536 536
 			});
537 537
 			/** @deprecated 21.0.0 use BeforeUserDeletedEvent event with the IEventDispatcher instead */
538
-			$userSession->listen('\OC\User', 'preDelete', function ($user) use ($legacyDispatcher) {
538
+			$userSession->listen('\OC\User', 'preDelete', function($user) use ($legacyDispatcher) {
539 539
 				/** @var \OC\User\User $user */
540 540
 				\OC_Hook::emit('OC_User', 'pre_deleteUser', ['run' => true, 'uid' => $user->getUID()]);
541 541
 				$legacyDispatcher->dispatch('OCP\IUser::preDelete', new GenericEvent($user));
542 542
 			});
543 543
 			/** @deprecated 21.0.0 use UserDeletedEvent event with the IEventDispatcher instead */
544
-			$userSession->listen('\OC\User', 'postDelete', function ($user) {
544
+			$userSession->listen('\OC\User', 'postDelete', function($user) {
545 545
 				/** @var \OC\User\User $user */
546 546
 				\OC_Hook::emit('OC_User', 'post_deleteUser', ['uid' => $user->getUID()]);
547 547
 			});
548
-			$userSession->listen('\OC\User', 'preSetPassword', function ($user, $password, $recoveryPassword) {
548
+			$userSession->listen('\OC\User', 'preSetPassword', function($user, $password, $recoveryPassword) {
549 549
 				/** @var \OC\User\User $user */
550 550
 				\OC_Hook::emit('OC_User', 'pre_setPassword', ['run' => true, 'uid' => $user->getUID(), 'password' => $password, 'recoveryPassword' => $recoveryPassword]);
551 551
 
@@ -553,7 +553,7 @@  discard block
 block discarded – undo
553 553
 				$dispatcher = $this->get(IEventDispatcher::class);
554 554
 				$dispatcher->dispatchTyped(new BeforePasswordUpdatedEvent($user, $password, $recoveryPassword));
555 555
 			});
556
-			$userSession->listen('\OC\User', 'postSetPassword', function ($user, $password, $recoveryPassword) {
556
+			$userSession->listen('\OC\User', 'postSetPassword', function($user, $password, $recoveryPassword) {
557 557
 				/** @var \OC\User\User $user */
558 558
 				\OC_Hook::emit('OC_User', 'post_setPassword', ['run' => true, 'uid' => $user->getUID(), 'password' => $password, 'recoveryPassword' => $recoveryPassword]);
559 559
 
@@ -561,14 +561,14 @@  discard block
 block discarded – undo
561 561
 				$dispatcher = $this->get(IEventDispatcher::class);
562 562
 				$dispatcher->dispatchTyped(new PasswordUpdatedEvent($user, $password, $recoveryPassword));
563 563
 			});
564
-			$userSession->listen('\OC\User', 'preLogin', function ($uid, $password) {
564
+			$userSession->listen('\OC\User', 'preLogin', function($uid, $password) {
565 565
 				\OC_Hook::emit('OC_User', 'pre_login', ['run' => true, 'uid' => $uid, 'password' => $password]);
566 566
 
567 567
 				/** @var IEventDispatcher $dispatcher */
568 568
 				$dispatcher = $this->get(IEventDispatcher::class);
569 569
 				$dispatcher->dispatchTyped(new BeforeUserLoggedInEvent($uid, $password));
570 570
 			});
571
-			$userSession->listen('\OC\User', 'postLogin', function ($user, $loginName, $password, $isTokenLogin) {
571
+			$userSession->listen('\OC\User', 'postLogin', function($user, $loginName, $password, $isTokenLogin) {
572 572
 				/** @var \OC\User\User $user */
573 573
 				\OC_Hook::emit('OC_User', 'post_login', ['run' => true, 'uid' => $user->getUID(), 'loginName' => $loginName, 'password' => $password, 'isTokenLogin' => $isTokenLogin]);
574 574
 
@@ -576,12 +576,12 @@  discard block
 block discarded – undo
576 576
 				$dispatcher = $this->get(IEventDispatcher::class);
577 577
 				$dispatcher->dispatchTyped(new UserLoggedInEvent($user, $password, $isTokenLogin));
578 578
 			});
579
-			$userSession->listen('\OC\User', 'preRememberedLogin', function ($uid) {
579
+			$userSession->listen('\OC\User', 'preRememberedLogin', function($uid) {
580 580
 				/** @var IEventDispatcher $dispatcher */
581 581
 				$dispatcher = $this->get(IEventDispatcher::class);
582 582
 				$dispatcher->dispatchTyped(new BeforeUserLoggedInWithCookieEvent($uid));
583 583
 			});
584
-			$userSession->listen('\OC\User', 'postRememberedLogin', function ($user, $password) {
584
+			$userSession->listen('\OC\User', 'postRememberedLogin', function($user, $password) {
585 585
 				/** @var \OC\User\User $user */
586 586
 				\OC_Hook::emit('OC_User', 'post_login', ['run' => true, 'uid' => $user->getUID(), 'password' => $password]);
587 587
 
@@ -589,19 +589,19 @@  discard block
 block discarded – undo
589 589
 				$dispatcher = $this->get(IEventDispatcher::class);
590 590
 				$dispatcher->dispatchTyped(new UserLoggedInWithCookieEvent($user, $password));
591 591
 			});
592
-			$userSession->listen('\OC\User', 'logout', function ($user) {
592
+			$userSession->listen('\OC\User', 'logout', function($user) {
593 593
 				\OC_Hook::emit('OC_User', 'logout', []);
594 594
 
595 595
 				/** @var IEventDispatcher $dispatcher */
596 596
 				$dispatcher = $this->get(IEventDispatcher::class);
597 597
 				$dispatcher->dispatchTyped(new BeforeUserLoggedOutEvent($user));
598 598
 			});
599
-			$userSession->listen('\OC\User', 'postLogout', function ($user) {
599
+			$userSession->listen('\OC\User', 'postLogout', function($user) {
600 600
 				/** @var IEventDispatcher $dispatcher */
601 601
 				$dispatcher = $this->get(IEventDispatcher::class);
602 602
 				$dispatcher->dispatchTyped(new UserLoggedOutEvent($user));
603 603
 			});
604
-			$userSession->listen('\OC\User', 'changeUser', function ($user, $feature, $value, $oldValue) {
604
+			$userSession->listen('\OC\User', 'changeUser', function($user, $feature, $value, $oldValue) {
605 605
 				/** @var \OC\User\User $user */
606 606
 				\OC_Hook::emit('OC_User', 'changeUser', ['run' => true, 'user' => $user, 'feature' => $feature, 'value' => $value, 'old_value' => $oldValue]);
607 607
 
@@ -625,7 +625,7 @@  discard block
 block discarded – undo
625 625
 		$this->registerDeprecatedAlias('AllConfig', \OC\AllConfig::class);
626 626
 		$this->registerAlias(\OCP\IConfig::class, \OC\AllConfig::class);
627 627
 
628
-		$this->registerService(\OC\SystemConfig::class, function ($c) use ($config) {
628
+		$this->registerService(\OC\SystemConfig::class, function($c) use ($config) {
629 629
 			return new \OC\SystemConfig($config);
630 630
 		});
631 631
 		/** @deprecated 19.0.0 */
@@ -635,7 +635,7 @@  discard block
 block discarded – undo
635 635
 		$this->registerDeprecatedAlias('AppConfig', \OC\AppConfig::class);
636 636
 		$this->registerAlias(IAppConfig::class, \OC\AppConfig::class);
637 637
 
638
-		$this->registerService(IFactory::class, function (Server $c) {
638
+		$this->registerService(IFactory::class, function(Server $c) {
639 639
 			return new \OC\L10N\Factory(
640 640
 				$c->get(\OCP\IConfig::class),
641 641
 				$c->getRequest(),
@@ -655,13 +655,13 @@  discard block
 block discarded – undo
655 655
 		/** @deprecated 19.0.0 */
656 656
 		$this->registerDeprecatedAlias('CategoryFetcher', CategoryFetcher::class);
657 657
 
658
-		$this->registerService(ICache::class, function ($c) {
658
+		$this->registerService(ICache::class, function($c) {
659 659
 			return new Cache\File();
660 660
 		});
661 661
 		/** @deprecated 19.0.0 */
662 662
 		$this->registerDeprecatedAlias('UserCache', ICache::class);
663 663
 
664
-		$this->registerService(Factory::class, function (Server $c) {
664
+		$this->registerService(Factory::class, function(Server $c) {
665 665
 			$arrayCacheFactory = new \OC\Memcache\Factory('', $c->get(ILogger::class),
666 666
 				ArrayCache::class,
667 667
 				ArrayCache::class,
@@ -676,7 +676,7 @@  discard block
 block discarded – undo
676 676
 				$version = implode(',', $v);
677 677
 				$instanceId = \OC_Util::getInstanceId();
678 678
 				$path = \OC::$SERVERROOT;
679
-				$prefix = md5($instanceId . '-' . $version . '-' . $path);
679
+				$prefix = md5($instanceId.'-'.$version.'-'.$path);
680 680
 				return new \OC\Memcache\Factory($prefix, $c->get(ILogger::class),
681 681
 					$config->getSystemValue('memcache.local', null),
682 682
 					$config->getSystemValue('memcache.distributed', null),
@@ -689,12 +689,12 @@  discard block
 block discarded – undo
689 689
 		$this->registerDeprecatedAlias('MemCacheFactory', Factory::class);
690 690
 		$this->registerAlias(ICacheFactory::class, Factory::class);
691 691
 
692
-		$this->registerService('RedisFactory', function (Server $c) {
692
+		$this->registerService('RedisFactory', function(Server $c) {
693 693
 			$systemConfig = $c->get(SystemConfig::class);
694 694
 			return new RedisFactory($systemConfig);
695 695
 		});
696 696
 
697
-		$this->registerService(\OCP\Activity\IManager::class, function (Server $c) {
697
+		$this->registerService(\OCP\Activity\IManager::class, function(Server $c) {
698 698
 			$l10n = $this->get(IFactory::class)->get('lib');
699 699
 			return new \OC\Activity\Manager(
700 700
 				$c->getRequest(),
@@ -707,14 +707,14 @@  discard block
 block discarded – undo
707 707
 		/** @deprecated 19.0.0 */
708 708
 		$this->registerDeprecatedAlias('ActivityManager', \OCP\Activity\IManager::class);
709 709
 
710
-		$this->registerService(\OCP\Activity\IEventMerger::class, function (Server $c) {
710
+		$this->registerService(\OCP\Activity\IEventMerger::class, function(Server $c) {
711 711
 			return new \OC\Activity\EventMerger(
712 712
 				$c->getL10N('lib')
713 713
 			);
714 714
 		});
715 715
 		$this->registerAlias(IValidator::class, Validator::class);
716 716
 
717
-		$this->registerService(AvatarManager::class, function (Server $c) {
717
+		$this->registerService(AvatarManager::class, function(Server $c) {
718 718
 			return new AvatarManager(
719 719
 				$c->get(\OC\User\Manager::class),
720 720
 				$c->getAppDataDir('avatar'),
@@ -730,7 +730,7 @@  discard block
 block discarded – undo
730 730
 		$this->registerAlias(\OCP\Support\CrashReport\IRegistry::class, \OC\Support\CrashReport\Registry::class);
731 731
 		$this->registerAlias(\OCP\Support\Subscription\IRegistry::class, \OC\Support\Subscription\Registry::class);
732 732
 
733
-		$this->registerService(\OC\Log::class, function (Server $c) {
733
+		$this->registerService(\OC\Log::class, function(Server $c) {
734 734
 			$logType = $c->get(AllConfig::class)->getSystemValue('log_type', 'file');
735 735
 			$factory = new LogFactory($c, $this->get(SystemConfig::class));
736 736
 			$logger = $factory->get($logType);
@@ -744,7 +744,7 @@  discard block
 block discarded – undo
744 744
 		// PSR-3 logger
745 745
 		$this->registerAlias(LoggerInterface::class, PsrLoggerAdapter::class);
746 746
 
747
-		$this->registerService(ILogFactory::class, function (Server $c) {
747
+		$this->registerService(ILogFactory::class, function(Server $c) {
748 748
 			return new LogFactory($c, $this->get(SystemConfig::class));
749 749
 		});
750 750
 
@@ -752,7 +752,7 @@  discard block
 block discarded – undo
752 752
 		/** @deprecated 19.0.0 */
753 753
 		$this->registerDeprecatedAlias('JobList', IJobList::class);
754 754
 
755
-		$this->registerService(Router::class, function (Server $c) {
755
+		$this->registerService(Router::class, function(Server $c) {
756 756
 			$cacheFactory = $c->get(ICacheFactory::class);
757 757
 			$logger = $c->get(ILogger::class);
758 758
 			if ($cacheFactory->isLocalCacheAvailable()) {
@@ -770,7 +770,7 @@  discard block
 block discarded – undo
770 770
 		/** @deprecated 19.0.0 */
771 771
 		$this->registerDeprecatedAlias('Search', ISearch::class);
772 772
 
773
-		$this->registerService(\OC\Security\RateLimiting\Backend\IBackend::class, function ($c) {
773
+		$this->registerService(\OC\Security\RateLimiting\Backend\IBackend::class, function($c) {
774 774
 			return new \OC\Security\RateLimiting\Backend\MemoryCache(
775 775
 				$this->get(ICacheFactory::class),
776 776
 				new \OC\AppFramework\Utility\TimeFactory()
@@ -793,7 +793,7 @@  discard block
 block discarded – undo
793 793
 		/** @deprecated 19.0.0 */
794 794
 		$this->registerDeprecatedAlias('CredentialsManager', ICredentialsManager::class);
795 795
 
796
-		$this->registerService(IDBConnection::class, function (Server $c) {
796
+		$this->registerService(IDBConnection::class, function(Server $c) {
797 797
 			$systemConfig = $c->get(SystemConfig::class);
798 798
 			$factory = new \OC\DB\ConnectionFactory($systemConfig);
799 799
 			$type = $systemConfig->getValue('dbtype', 'sqlite');
@@ -811,7 +811,7 @@  discard block
 block discarded – undo
811 811
 		$this->registerAlias(ICertificateManager::class, CertificateManager::class);
812 812
 		$this->registerAlias(IClientService::class, ClientService::class);
813 813
 		$this->registerDeprecatedAlias('HttpClientService', IClientService::class);
814
-		$this->registerService(IEventLogger::class, function (ContainerInterface $c) {
814
+		$this->registerService(IEventLogger::class, function(ContainerInterface $c) {
815 815
 			$eventLogger = new EventLogger();
816 816
 			if ($c->get(SystemConfig::class)->getValue('debug', false)) {
817 817
 				// In debug mode, module is being activated by default
@@ -822,7 +822,7 @@  discard block
 block discarded – undo
822 822
 		/** @deprecated 19.0.0 */
823 823
 		$this->registerDeprecatedAlias('EventLogger', IEventLogger::class);
824 824
 
825
-		$this->registerService(IQueryLogger::class, function (ContainerInterface $c) {
825
+		$this->registerService(IQueryLogger::class, function(ContainerInterface $c) {
826 826
 			$queryLogger = new QueryLogger();
827 827
 			if ($c->get(SystemConfig::class)->getValue('debug', false)) {
828 828
 				// In debug mode, module is being activated by default
@@ -837,7 +837,7 @@  discard block
 block discarded – undo
837 837
 		$this->registerDeprecatedAlias('TempManager', TempManager::class);
838 838
 		$this->registerAlias(ITempManager::class, TempManager::class);
839 839
 
840
-		$this->registerService(AppManager::class, function (ContainerInterface $c) {
840
+		$this->registerService(AppManager::class, function(ContainerInterface $c) {
841 841
 			// TODO: use auto-wiring
842 842
 			return new \OC\App\AppManager(
843 843
 				$c->get(IUserSession::class),
@@ -857,7 +857,7 @@  discard block
 block discarded – undo
857 857
 		/** @deprecated 19.0.0 */
858 858
 		$this->registerDeprecatedAlias('DateTimeZone', IDateTimeZone::class);
859 859
 
860
-		$this->registerService(IDateTimeFormatter::class, function (Server $c) {
860
+		$this->registerService(IDateTimeFormatter::class, function(Server $c) {
861 861
 			$language = $c->get(\OCP\IConfig::class)->getUserValue($c->get(ISession::class)->get('user_id'), 'core', 'lang', null);
862 862
 
863 863
 			return new DateTimeFormatter(
@@ -868,7 +868,7 @@  discard block
 block discarded – undo
868 868
 		/** @deprecated 19.0.0 */
869 869
 		$this->registerDeprecatedAlias('DateTimeFormatter', IDateTimeFormatter::class);
870 870
 
871
-		$this->registerService(IUserMountCache::class, function (ContainerInterface $c) {
871
+		$this->registerService(IUserMountCache::class, function(ContainerInterface $c) {
872 872
 			$mountCache = new UserMountCache(
873 873
 				$c->get(IDBConnection::class),
874 874
 				$c->get(IUserManager::class),
@@ -881,7 +881,7 @@  discard block
 block discarded – undo
881 881
 		/** @deprecated 19.0.0 */
882 882
 		$this->registerDeprecatedAlias('UserMountCache', IUserMountCache::class);
883 883
 
884
-		$this->registerService(IMountProviderCollection::class, function (ContainerInterface $c) {
884
+		$this->registerService(IMountProviderCollection::class, function(ContainerInterface $c) {
885 885
 			$loader = \OC\Files\Filesystem::getLoader();
886 886
 			$mountCache = $c->get(IUserMountCache::class);
887 887
 			$manager = new \OC\Files\Config\MountProviderCollection($loader, $mountCache);
@@ -902,7 +902,7 @@  discard block
 block discarded – undo
902 902
 
903 903
 		/** @deprecated 20.0.0 */
904 904
 		$this->registerDeprecatedAlias('IniWrapper', IniGetWrapper::class);
905
-		$this->registerService(IBus::class, function (ContainerInterface $c) {
905
+		$this->registerService(IBus::class, function(ContainerInterface $c) {
906 906
 			$busClass = $c->get(\OCP\IConfig::class)->getSystemValue('commandbus');
907 907
 			if ($busClass) {
908 908
 				[$app, $class] = explode('::', $busClass, 2);
@@ -922,7 +922,7 @@  discard block
 block discarded – undo
922 922
 		$this->registerDeprecatedAlias('TrustedDomainHelper', TrustedDomainHelper::class);
923 923
 		/** @deprecated 19.0.0 */
924 924
 		$this->registerDeprecatedAlias('Throttler', Throttler::class);
925
-		$this->registerService('IntegrityCodeChecker', function (ContainerInterface $c) {
925
+		$this->registerService('IntegrityCodeChecker', function(ContainerInterface $c) {
926 926
 			// IConfig and IAppManager requires a working database. This code
927 927
 			// might however be called when ownCloud is not yet setup.
928 928
 			if (\OC::$server->get(SystemConfig::class)->getValue('installed', false)) {
@@ -944,7 +944,7 @@  discard block
 block discarded – undo
944 944
 				$c->get(IMimeTypeDetector::class)
945 945
 			);
946 946
 		});
947
-		$this->registerService(\OCP\IRequest::class, function (ContainerInterface $c) {
947
+		$this->registerService(\OCP\IRequest::class, function(ContainerInterface $c) {
948 948
 			if (isset($this['urlParams'])) {
949 949
 				$urlParams = $this['urlParams'];
950 950
 			} else {
@@ -981,7 +981,7 @@  discard block
 block discarded – undo
981 981
 		/** @deprecated 19.0.0 */
982 982
 		$this->registerDeprecatedAlias('Request', \OCP\IRequest::class);
983 983
 
984
-		$this->registerService(IMailer::class, function (Server $c) {
984
+		$this->registerService(IMailer::class, function(Server $c) {
985 985
 			return new Mailer(
986 986
 				$c->get(\OCP\IConfig::class),
987 987
 				$c->get(ILogger::class),
@@ -995,7 +995,7 @@  discard block
 block discarded – undo
995 995
 		/** @deprecated 19.0.0 */
996 996
 		$this->registerDeprecatedAlias('Mailer', IMailer::class);
997 997
 
998
-		$this->registerService('LDAPProvider', function (ContainerInterface $c) {
998
+		$this->registerService('LDAPProvider', function(ContainerInterface $c) {
999 999
 			$config = $c->get(\OCP\IConfig::class);
1000 1000
 			$factoryClass = $config->getSystemValue('ldapProviderFactory', null);
1001 1001
 			if (is_null($factoryClass)) {
@@ -1005,7 +1005,7 @@  discard block
 block discarded – undo
1005 1005
 			$factory = new $factoryClass($this);
1006 1006
 			return $factory->getLDAPProvider();
1007 1007
 		});
1008
-		$this->registerService(ILockingProvider::class, function (ContainerInterface $c) {
1008
+		$this->registerService(ILockingProvider::class, function(ContainerInterface $c) {
1009 1009
 			$ini = $c->get(IniGetWrapper::class);
1010 1010
 			$config = $c->get(\OCP\IConfig::class);
1011 1011
 			$ttl = $config->getSystemValue('filelocking.ttl', max(3600, $ini->getNumeric('max_execution_time')));
@@ -1033,12 +1033,12 @@  discard block
 block discarded – undo
1033 1033
 		/** @deprecated 19.0.0 */
1034 1034
 		$this->registerDeprecatedAlias('MountManager', IMountManager::class);
1035 1035
 
1036
-		$this->registerService(IMimeTypeDetector::class, function (ContainerInterface $c) {
1036
+		$this->registerService(IMimeTypeDetector::class, function(ContainerInterface $c) {
1037 1037
 			return new \OC\Files\Type\Detection(
1038 1038
 				$c->get(IURLGenerator::class),
1039 1039
 				$c->get(ILogger::class),
1040 1040
 				\OC::$configDir,
1041
-				\OC::$SERVERROOT . '/resources/config/'
1041
+				\OC::$SERVERROOT.'/resources/config/'
1042 1042
 			);
1043 1043
 		});
1044 1044
 		/** @deprecated 19.0.0 */
@@ -1047,19 +1047,19 @@  discard block
 block discarded – undo
1047 1047
 		$this->registerAlias(IMimeTypeLoader::class, Loader::class);
1048 1048
 		/** @deprecated 19.0.0 */
1049 1049
 		$this->registerDeprecatedAlias('MimeTypeLoader', IMimeTypeLoader::class);
1050
-		$this->registerService(BundleFetcher::class, function () {
1050
+		$this->registerService(BundleFetcher::class, function() {
1051 1051
 			return new BundleFetcher($this->getL10N('lib'));
1052 1052
 		});
1053 1053
 		$this->registerAlias(\OCP\Notification\IManager::class, Manager::class);
1054 1054
 		/** @deprecated 19.0.0 */
1055 1055
 		$this->registerDeprecatedAlias('NotificationManager', \OCP\Notification\IManager::class);
1056 1056
 
1057
-		$this->registerService(CapabilitiesManager::class, function (ContainerInterface $c) {
1057
+		$this->registerService(CapabilitiesManager::class, function(ContainerInterface $c) {
1058 1058
 			$manager = new CapabilitiesManager($c->get(ILogger::class));
1059
-			$manager->registerCapability(function () use ($c) {
1059
+			$manager->registerCapability(function() use ($c) {
1060 1060
 				return new \OC\OCS\CoreCapabilities($c->get(\OCP\IConfig::class));
1061 1061
 			});
1062
-			$manager->registerCapability(function () use ($c) {
1062
+			$manager->registerCapability(function() use ($c) {
1063 1063
 				return $c->get(\OC\Security\Bruteforce\Capabilities::class);
1064 1064
 			});
1065 1065
 			return $manager;
@@ -1067,14 +1067,14 @@  discard block
 block discarded – undo
1067 1067
 		/** @deprecated 19.0.0 */
1068 1068
 		$this->registerDeprecatedAlias('CapabilitiesManager', CapabilitiesManager::class);
1069 1069
 
1070
-		$this->registerService(ICommentsManager::class, function (Server $c) {
1070
+		$this->registerService(ICommentsManager::class, function(Server $c) {
1071 1071
 			$config = $c->get(\OCP\IConfig::class);
1072 1072
 			$factoryClass = $config->getSystemValue('comments.managerFactory', CommentsManagerFactory::class);
1073 1073
 			/** @var \OCP\Comments\ICommentsManagerFactory $factory */
1074 1074
 			$factory = new $factoryClass($this);
1075 1075
 			$manager = $factory->getManager();
1076 1076
 
1077
-			$manager->registerDisplayNameResolver('user', function ($id) use ($c) {
1077
+			$manager->registerDisplayNameResolver('user', function($id) use ($c) {
1078 1078
 				$manager = $c->get(IUserManager::class);
1079 1079
 				$user = $manager->get($id);
1080 1080
 				if (is_null($user)) {
@@ -1092,7 +1092,7 @@  discard block
 block discarded – undo
1092 1092
 		$this->registerDeprecatedAlias('CommentsManager', ICommentsManager::class);
1093 1093
 
1094 1094
 		$this->registerAlias(\OC_Defaults::class, 'ThemingDefaults');
1095
-		$this->registerService('ThemingDefaults', function (Server $c) {
1095
+		$this->registerService('ThemingDefaults', function(Server $c) {
1096 1096
 			/*
1097 1097
 			 * Dark magic for autoloader.
1098 1098
 			 * If we do a class_exists it will try to load the class which will
@@ -1127,7 +1127,7 @@  discard block
 block discarded – undo
1127 1127
 			}
1128 1128
 			return new \OC_Defaults();
1129 1129
 		});
1130
-		$this->registerService(JSCombiner::class, function (Server $c) {
1130
+		$this->registerService(JSCombiner::class, function(Server $c) {
1131 1131
 			return new JSCombiner(
1132 1132
 				$c->getAppDataDir('js'),
1133 1133
 				$c->get(IURLGenerator::class),
@@ -1141,7 +1141,7 @@  discard block
 block discarded – undo
1141 1141
 		$this->registerDeprecatedAlias('EventDispatcher', \OC\EventDispatcher\SymfonyAdapter::class);
1142 1142
 		$this->registerAlias(EventDispatcherInterface::class, \OC\EventDispatcher\SymfonyAdapter::class);
1143 1143
 
1144
-		$this->registerService('CryptoWrapper', function (ContainerInterface $c) {
1144
+		$this->registerService('CryptoWrapper', function(ContainerInterface $c) {
1145 1145
 			// FIXME: Instantiiated here due to cyclic dependency
1146 1146
 			$request = new Request(
1147 1147
 				[
@@ -1168,14 +1168,14 @@  discard block
 block discarded – undo
1168 1168
 		});
1169 1169
 		/** @deprecated 19.0.0 */
1170 1170
 		$this->registerDeprecatedAlias('CsrfTokenManager', CsrfTokenManager::class);
1171
-		$this->registerService(SessionStorage::class, function (ContainerInterface $c) {
1171
+		$this->registerService(SessionStorage::class, function(ContainerInterface $c) {
1172 1172
 			return new SessionStorage($c->get(ISession::class));
1173 1173
 		});
1174 1174
 		$this->registerAlias(\OCP\Security\IContentSecurityPolicyManager::class, ContentSecurityPolicyManager::class);
1175 1175
 		/** @deprecated 19.0.0 */
1176 1176
 		$this->registerDeprecatedAlias('ContentSecurityPolicyManager', ContentSecurityPolicyManager::class);
1177 1177
 
1178
-		$this->registerService(\OCP\Share\IManager::class, function (IServerContainer $c) {
1178
+		$this->registerService(\OCP\Share\IManager::class, function(IServerContainer $c) {
1179 1179
 			$config = $c->get(\OCP\IConfig::class);
1180 1180
 			$factoryClass = $config->getSystemValue('sharing.managerFactory', ProviderFactory::class);
1181 1181
 			/** @var \OCP\Share\IProviderFactory $factory */
@@ -1205,7 +1205,7 @@  discard block
 block discarded – undo
1205 1205
 		/** @deprecated 19.0.0 */
1206 1206
 		$this->registerDeprecatedAlias('ShareManager', \OCP\Share\IManager::class);
1207 1207
 
1208
-		$this->registerService(\OCP\Collaboration\Collaborators\ISearch::class, function (Server $c) {
1208
+		$this->registerService(\OCP\Collaboration\Collaborators\ISearch::class, function(Server $c) {
1209 1209
 			$instance = new Collaboration\Collaborators\Search($c);
1210 1210
 
1211 1211
 			// register default plugins
@@ -1228,33 +1228,33 @@  discard block
 block discarded – undo
1228 1228
 
1229 1229
 		$this->registerDeprecatedAlias('SettingsManager', \OC\Settings\Manager::class);
1230 1230
 		$this->registerAlias(\OCP\Settings\IManager::class, \OC\Settings\Manager::class);
1231
-		$this->registerService(\OC\Files\AppData\Factory::class, function (ContainerInterface $c) {
1231
+		$this->registerService(\OC\Files\AppData\Factory::class, function(ContainerInterface $c) {
1232 1232
 			return new \OC\Files\AppData\Factory(
1233 1233
 				$c->get(IRootFolder::class),
1234 1234
 				$c->get(SystemConfig::class)
1235 1235
 			);
1236 1236
 		});
1237 1237
 
1238
-		$this->registerService('LockdownManager', function (ContainerInterface $c) {
1239
-			return new LockdownManager(function () use ($c) {
1238
+		$this->registerService('LockdownManager', function(ContainerInterface $c) {
1239
+			return new LockdownManager(function() use ($c) {
1240 1240
 				return $c->get(ISession::class);
1241 1241
 			});
1242 1242
 		});
1243 1243
 
1244
-		$this->registerService(\OCP\OCS\IDiscoveryService::class, function (ContainerInterface $c) {
1244
+		$this->registerService(\OCP\OCS\IDiscoveryService::class, function(ContainerInterface $c) {
1245 1245
 			return new DiscoveryService(
1246 1246
 				$c->get(ICacheFactory::class),
1247 1247
 				$c->get(IClientService::class)
1248 1248
 			);
1249 1249
 		});
1250 1250
 
1251
-		$this->registerService(ICloudIdManager::class, function (ContainerInterface $c) {
1251
+		$this->registerService(ICloudIdManager::class, function(ContainerInterface $c) {
1252 1252
 			return new CloudIdManager($c->get(\OCP\Contacts\IManager::class));
1253 1253
 		});
1254 1254
 
1255 1255
 		$this->registerAlias(\OCP\GlobalScale\IConfig::class, \OC\GlobalScale\Config::class);
1256 1256
 
1257
-		$this->registerService(ICloudFederationProviderManager::class, function (ContainerInterface $c) {
1257
+		$this->registerService(ICloudFederationProviderManager::class, function(ContainerInterface $c) {
1258 1258
 			return new CloudFederationProviderManager(
1259 1259
 				$c->get(IAppManager::class),
1260 1260
 				$c->get(IClientService::class),
@@ -1263,7 +1263,7 @@  discard block
 block discarded – undo
1263 1263
 			);
1264 1264
 		});
1265 1265
 
1266
-		$this->registerService(ICloudFederationFactory::class, function (Server $c) {
1266
+		$this->registerService(ICloudFederationFactory::class, function(Server $c) {
1267 1267
 			return new CloudFederationFactory();
1268 1268
 		});
1269 1269
 
@@ -1275,7 +1275,7 @@  discard block
 block discarded – undo
1275 1275
 		/** @deprecated 19.0.0 */
1276 1276
 		$this->registerDeprecatedAlias('TimeFactory', \OCP\AppFramework\Utility\ITimeFactory::class);
1277 1277
 
1278
-		$this->registerService(Defaults::class, function (Server $c) {
1278
+		$this->registerService(Defaults::class, function(Server $c) {
1279 1279
 			return new Defaults(
1280 1280
 				$c->getThemingDefaults()
1281 1281
 			);
@@ -1283,17 +1283,17 @@  discard block
 block discarded – undo
1283 1283
 		/** @deprecated 19.0.0 */
1284 1284
 		$this->registerDeprecatedAlias('Defaults', \OCP\Defaults::class);
1285 1285
 
1286
-		$this->registerService(\OCP\ISession::class, function (ContainerInterface $c) {
1286
+		$this->registerService(\OCP\ISession::class, function(ContainerInterface $c) {
1287 1287
 			return $c->get(\OCP\IUserSession::class)->getSession();
1288 1288
 		}, false);
1289 1289
 
1290
-		$this->registerService(IShareHelper::class, function (ContainerInterface $c) {
1290
+		$this->registerService(IShareHelper::class, function(ContainerInterface $c) {
1291 1291
 			return new ShareHelper(
1292 1292
 				$c->get(\OCP\Share\IManager::class)
1293 1293
 			);
1294 1294
 		});
1295 1295
 
1296
-		$this->registerService(Installer::class, function (ContainerInterface $c) {
1296
+		$this->registerService(Installer::class, function(ContainerInterface $c) {
1297 1297
 			return new Installer(
1298 1298
 				$c->get(AppFetcher::class),
1299 1299
 				$c->get(IClientService::class),
@@ -1304,11 +1304,11 @@  discard block
 block discarded – undo
1304 1304
 			);
1305 1305
 		});
1306 1306
 
1307
-		$this->registerService(IApiFactory::class, function (ContainerInterface $c) {
1307
+		$this->registerService(IApiFactory::class, function(ContainerInterface $c) {
1308 1308
 			return new ApiFactory($c->get(IClientService::class));
1309 1309
 		});
1310 1310
 
1311
-		$this->registerService(IInstanceFactory::class, function (ContainerInterface $c) {
1311
+		$this->registerService(IInstanceFactory::class, function(ContainerInterface $c) {
1312 1312
 			$memcacheFactory = $c->get(ICacheFactory::class);
1313 1313
 			return new InstanceFactory($memcacheFactory->createLocal('remoteinstance.'), $c->get(IClientService::class));
1314 1314
 		});
@@ -1365,7 +1365,7 @@  discard block
 block discarded – undo
1365 1365
 		$dispatcher = $this->get(SymfonyAdapter::class);
1366 1366
 
1367 1367
 		// Delete avatar on user deletion
1368
-		$dispatcher->addListener('OCP\IUser::preDelete', function (GenericEvent $e) {
1368
+		$dispatcher->addListener('OCP\IUser::preDelete', function(GenericEvent $e) {
1369 1369
 			$logger = $this->get(ILogger::class);
1370 1370
 			$manager = $this->getAvatarManager();
1371 1371
 			/** @var IUser $user */
@@ -1378,11 +1378,11 @@  discard block
 block discarded – undo
1378 1378
 				// no avatar to remove
1379 1379
 			} catch (\Exception $e) {
1380 1380
 				// Ignore exceptions
1381
-				$logger->info('Could not cleanup avatar of ' . $user->getUID());
1381
+				$logger->info('Could not cleanup avatar of '.$user->getUID());
1382 1382
 			}
1383 1383
 		});
1384 1384
 
1385
-		$dispatcher->addListener('OCP\IUser::changeUser', function (GenericEvent $e) {
1385
+		$dispatcher->addListener('OCP\IUser::changeUser', function(GenericEvent $e) {
1386 1386
 			$manager = $this->getAvatarManager();
1387 1387
 			/** @var IUser $user */
1388 1388
 			$user = $e->getSubject();
@@ -2273,11 +2273,11 @@  discard block
 block discarded – undo
2273 2273
 	}
2274 2274
 
2275 2275
 	private function registerDeprecatedAlias(string $alias, string $target) {
2276
-		$this->registerService($alias, function (ContainerInterface $container) use ($target, $alias) {
2276
+		$this->registerService($alias, function(ContainerInterface $container) use ($target, $alias) {
2277 2277
 			try {
2278 2278
 				/** @var ILogger $logger */
2279 2279
 				$logger = $container->get(ILogger::class);
2280
-				$logger->debug('The requested alias "' . $alias . '" is deprecated. Please request "' . $target . '" directly. This alias will be removed in a future Nextcloud version.', ['app' => 'serverDI']);
2280
+				$logger->debug('The requested alias "'.$alias.'" is deprecated. Please request "'.$target.'" directly. This alias will be removed in a future Nextcloud version.', ['app' => 'serverDI']);
2281 2281
 			} catch (ContainerExceptionInterface $e) {
2282 2282
 				// Could not get logger. Continue
2283 2283
 			}
Please login to merge, or discard this patch.
lib/private/User/User.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
 	 */
216 216
 	public function delete() {
217 217
 		/** @deprecated 21.0.0 use BeforeUserDeletedEvent event with the IEventDispatcher instead */
218
-		$this->legacyDispatcher->dispatch(IUser::class . '::preDelete', new GenericEvent($this));
218
+		$this->legacyDispatcher->dispatch(IUser::class.'::preDelete', new GenericEvent($this));
219 219
 		if ($this->emitter) {
220 220
 			/** @deprecated 21.0.0 use BeforeUserDeletedEvent event with the IEventDispatcher instead */
221 221
 			$this->emitter->emit('\OC\User', 'preDelete', [$this]);
@@ -249,7 +249,7 @@  discard block
 block discarded – undo
249 249
 			}
250 250
 
251 251
 			// Delete the users entry in the storage table
252
-			Storage::remove('home::' . $this->uid);
252
+			Storage::remove('home::'.$this->uid);
253 253
 
254 254
 			\OC::$server->getCommentsManager()->deleteReferencesOfActor('users', $this->uid);
255 255
 			\OC::$server->getCommentsManager()->deleteReadMarksFromUser($this);
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
 			$accountManager->deleteUser($this);
268 268
 
269 269
 			/** @deprecated 21.0.0 use UserDeletedEvent event with the IEventDispatcher instead */
270
-			$this->legacyDispatcher->dispatch(IUser::class . '::postDelete', new GenericEvent($this));
270
+			$this->legacyDispatcher->dispatch(IUser::class.'::postDelete', new GenericEvent($this));
271 271
 			if ($this->emitter) {
272 272
 				/** @deprecated 21.0.0 use UserDeletedEvent event with the IEventDispatcher instead */
273 273
 				$this->emitter->emit('\OC\User', 'postDelete', [$this]);
@@ -285,7 +285,7 @@  discard block
 block discarded – undo
285 285
 	 * @return bool
286 286
 	 */
287 287
 	public function setPassword($password, $recoveryPassword = null) {
288
-		$this->legacyDispatcher->dispatch(IUser::class . '::preSetPassword', new GenericEvent($this, [
288
+		$this->legacyDispatcher->dispatch(IUser::class.'::preSetPassword', new GenericEvent($this, [
289 289
 			'password' => $password,
290 290
 			'recoveryPassword' => $recoveryPassword,
291 291
 		]));
@@ -294,7 +294,7 @@  discard block
 block discarded – undo
294 294
 		}
295 295
 		if ($this->backend->implementsActions(Backend::SET_PASSWORD)) {
296 296
 			$result = $this->backend->setPassword($this->uid, $password);
297
-			$this->legacyDispatcher->dispatch(IUser::class . '::postSetPassword', new GenericEvent($this, [
297
+			$this->legacyDispatcher->dispatch(IUser::class.'::postSetPassword', new GenericEvent($this, [
298 298
 				'password' => $password,
299 299
 				'recoveryPassword' => $recoveryPassword,
300 300
 			]));
@@ -317,9 +317,9 @@  discard block
 block discarded – undo
317 317
 			if ($this->backend->implementsActions(Backend::GET_HOME) and $home = $this->backend->getHome($this->uid)) {
318 318
 				$this->home = $home;
319 319
 			} elseif ($this->config) {
320
-				$this->home = $this->config->getSystemValue('datadirectory', \OC::$SERVERROOT . '/data') . '/' . $this->uid;
320
+				$this->home = $this->config->getSystemValue('datadirectory', \OC::$SERVERROOT.'/data').'/'.$this->uid;
321 321
 			} else {
322
-				$this->home = \OC::$SERVERROOT . '/data/' . $this->uid;
322
+				$this->home = \OC::$SERVERROOT.'/data/'.$this->uid;
323 323
 			}
324 324
 		}
325 325
 		return $this->home;
@@ -499,7 +499,7 @@  discard block
 block discarded – undo
499 499
 	}
500 500
 
501 501
 	public function triggerChange($feature, $value = null, $oldValue = null) {
502
-		$this->legacyDispatcher->dispatch(IUser::class . '::changeUser', new GenericEvent($this, [
502
+		$this->legacyDispatcher->dispatch(IUser::class.'::changeUser', new GenericEvent($this, [
503 503
 			'feature' => $feature,
504 504
 			'value' => $value,
505 505
 			'oldValue' => $oldValue,
Please login to merge, or discard this patch.