Passed
Push — master ( 346770...2398d1 )
by Roeland
10:40 queued 35s
created
apps/files/composer/composer/autoload_static.php 1 patch
Spacing   +37 added lines, -37 removed lines patch added patch discarded remove patch
@@ -6,56 +6,56 @@
 block discarded – undo
6 6
 
7 7
 class ComposerStaticInitFiles
8 8
 {
9
-    public static $prefixLengthsPsr4 = array (
9
+    public static $prefixLengthsPsr4 = array(
10 10
         'O' => 
11
-        array (
11
+        array(
12 12
             'OCA\\Files\\' => 10,
13 13
         ),
14 14
     );
15 15
 
16
-    public static $prefixDirsPsr4 = array (
16
+    public static $prefixDirsPsr4 = array(
17 17
         'OCA\\Files\\' => 
18
-        array (
19
-            0 => __DIR__ . '/..' . '/../lib',
18
+        array(
19
+            0 => __DIR__.'/..'.'/../lib',
20 20
         ),
21 21
     );
22 22
 
23
-    public static $classMap = array (
24
-        'OCA\\Files\\Activity\\FavoriteProvider' => __DIR__ . '/..' . '/../lib/Activity/FavoriteProvider.php',
25
-        'OCA\\Files\\Activity\\Filter\\Favorites' => __DIR__ . '/..' . '/../lib/Activity/Filter/Favorites.php',
26
-        'OCA\\Files\\Activity\\Filter\\FileChanges' => __DIR__ . '/..' . '/../lib/Activity/Filter/FileChanges.php',
27
-        'OCA\\Files\\Activity\\Helper' => __DIR__ . '/..' . '/../lib/Activity/Helper.php',
28
-        'OCA\\Files\\Activity\\Provider' => __DIR__ . '/..' . '/../lib/Activity/Provider.php',
29
-        'OCA\\Files\\Activity\\Settings\\FavoriteAction' => __DIR__ . '/..' . '/../lib/Activity/Settings/FavoriteAction.php',
30
-        'OCA\\Files\\Activity\\Settings\\FileChanged' => __DIR__ . '/..' . '/../lib/Activity/Settings/FileChanged.php',
31
-        'OCA\\Files\\Activity\\Settings\\FileCreated' => __DIR__ . '/..' . '/../lib/Activity/Settings/FileCreated.php',
32
-        'OCA\\Files\\Activity\\Settings\\FileDeleted' => __DIR__ . '/..' . '/../lib/Activity/Settings/FileDeleted.php',
33
-        'OCA\\Files\\Activity\\Settings\\FileFavorite' => __DIR__ . '/..' . '/../lib/Activity/Settings/FileFavorite.php',
34
-        'OCA\\Files\\Activity\\Settings\\FileRestored' => __DIR__ . '/..' . '/../lib/Activity/Settings/FileRestored.php',
35
-        'OCA\\Files\\App' => __DIR__ . '/..' . '/../lib/App.php',
36
-        'OCA\\Files\\AppInfo\\Application' => __DIR__ . '/..' . '/../lib/AppInfo/Application.php',
37
-        'OCA\\Files\\BackgroundJob\\CleanupFileLocks' => __DIR__ . '/..' . '/../lib/BackgroundJob/CleanupFileLocks.php',
38
-        'OCA\\Files\\BackgroundJob\\DeleteOrphanedItems' => __DIR__ . '/..' . '/../lib/BackgroundJob/DeleteOrphanedItems.php',
39
-        'OCA\\Files\\BackgroundJob\\ScanFiles' => __DIR__ . '/..' . '/../lib/BackgroundJob/ScanFiles.php',
40
-        'OCA\\Files\\Capabilities' => __DIR__ . '/..' . '/../lib/Capabilities.php',
41
-        'OCA\\Files\\Collaboration\\Resources\\Listener' => __DIR__ . '/..' . '/../lib/Collaboration/Resources/Listener.php',
42
-        'OCA\\Files\\Collaboration\\Resources\\ResourceProvider' => __DIR__ . '/..' . '/../lib/Collaboration/Resources/ResourceProvider.php',
43
-        'OCA\\Files\\Command\\DeleteOrphanedFiles' => __DIR__ . '/..' . '/../lib/Command/DeleteOrphanedFiles.php',
44
-        'OCA\\Files\\Command\\Scan' => __DIR__ . '/..' . '/../lib/Command/Scan.php',
45
-        'OCA\\Files\\Command\\ScanAppData' => __DIR__ . '/..' . '/../lib/Command/ScanAppData.php',
46
-        'OCA\\Files\\Command\\TransferOwnership' => __DIR__ . '/..' . '/../lib/Command/TransferOwnership.php',
47
-        'OCA\\Files\\Controller\\AjaxController' => __DIR__ . '/..' . '/../lib/Controller/AjaxController.php',
48
-        'OCA\\Files\\Controller\\ApiController' => __DIR__ . '/..' . '/../lib/Controller/ApiController.php',
49
-        'OCA\\Files\\Controller\\SettingsController' => __DIR__ . '/..' . '/../lib/Controller/SettingsController.php',
50
-        'OCA\\Files\\Controller\\ViewController' => __DIR__ . '/..' . '/../lib/Controller/ViewController.php',
51
-        'OCA\\Files\\Helper' => __DIR__ . '/..' . '/../lib/Helper.php',
52
-        'OCA\\Files\\Service\\TagService' => __DIR__ . '/..' . '/../lib/Service/TagService.php',
53
-        'OCA\\Files\\Settings\\Admin' => __DIR__ . '/..' . '/../lib/Settings/Admin.php',
23
+    public static $classMap = array(
24
+        'OCA\\Files\\Activity\\FavoriteProvider' => __DIR__.'/..'.'/../lib/Activity/FavoriteProvider.php',
25
+        'OCA\\Files\\Activity\\Filter\\Favorites' => __DIR__.'/..'.'/../lib/Activity/Filter/Favorites.php',
26
+        'OCA\\Files\\Activity\\Filter\\FileChanges' => __DIR__.'/..'.'/../lib/Activity/Filter/FileChanges.php',
27
+        'OCA\\Files\\Activity\\Helper' => __DIR__.'/..'.'/../lib/Activity/Helper.php',
28
+        'OCA\\Files\\Activity\\Provider' => __DIR__.'/..'.'/../lib/Activity/Provider.php',
29
+        'OCA\\Files\\Activity\\Settings\\FavoriteAction' => __DIR__.'/..'.'/../lib/Activity/Settings/FavoriteAction.php',
30
+        'OCA\\Files\\Activity\\Settings\\FileChanged' => __DIR__.'/..'.'/../lib/Activity/Settings/FileChanged.php',
31
+        'OCA\\Files\\Activity\\Settings\\FileCreated' => __DIR__.'/..'.'/../lib/Activity/Settings/FileCreated.php',
32
+        'OCA\\Files\\Activity\\Settings\\FileDeleted' => __DIR__.'/..'.'/../lib/Activity/Settings/FileDeleted.php',
33
+        'OCA\\Files\\Activity\\Settings\\FileFavorite' => __DIR__.'/..'.'/../lib/Activity/Settings/FileFavorite.php',
34
+        'OCA\\Files\\Activity\\Settings\\FileRestored' => __DIR__.'/..'.'/../lib/Activity/Settings/FileRestored.php',
35
+        'OCA\\Files\\App' => __DIR__.'/..'.'/../lib/App.php',
36
+        'OCA\\Files\\AppInfo\\Application' => __DIR__.'/..'.'/../lib/AppInfo/Application.php',
37
+        'OCA\\Files\\BackgroundJob\\CleanupFileLocks' => __DIR__.'/..'.'/../lib/BackgroundJob/CleanupFileLocks.php',
38
+        'OCA\\Files\\BackgroundJob\\DeleteOrphanedItems' => __DIR__.'/..'.'/../lib/BackgroundJob/DeleteOrphanedItems.php',
39
+        'OCA\\Files\\BackgroundJob\\ScanFiles' => __DIR__.'/..'.'/../lib/BackgroundJob/ScanFiles.php',
40
+        'OCA\\Files\\Capabilities' => __DIR__.'/..'.'/../lib/Capabilities.php',
41
+        'OCA\\Files\\Collaboration\\Resources\\Listener' => __DIR__.'/..'.'/../lib/Collaboration/Resources/Listener.php',
42
+        'OCA\\Files\\Collaboration\\Resources\\ResourceProvider' => __DIR__.'/..'.'/../lib/Collaboration/Resources/ResourceProvider.php',
43
+        'OCA\\Files\\Command\\DeleteOrphanedFiles' => __DIR__.'/..'.'/../lib/Command/DeleteOrphanedFiles.php',
44
+        'OCA\\Files\\Command\\Scan' => __DIR__.'/..'.'/../lib/Command/Scan.php',
45
+        'OCA\\Files\\Command\\ScanAppData' => __DIR__.'/..'.'/../lib/Command/ScanAppData.php',
46
+        'OCA\\Files\\Command\\TransferOwnership' => __DIR__.'/..'.'/../lib/Command/TransferOwnership.php',
47
+        'OCA\\Files\\Controller\\AjaxController' => __DIR__.'/..'.'/../lib/Controller/AjaxController.php',
48
+        'OCA\\Files\\Controller\\ApiController' => __DIR__.'/..'.'/../lib/Controller/ApiController.php',
49
+        'OCA\\Files\\Controller\\SettingsController' => __DIR__.'/..'.'/../lib/Controller/SettingsController.php',
50
+        'OCA\\Files\\Controller\\ViewController' => __DIR__.'/..'.'/../lib/Controller/ViewController.php',
51
+        'OCA\\Files\\Helper' => __DIR__.'/..'.'/../lib/Helper.php',
52
+        'OCA\\Files\\Service\\TagService' => __DIR__.'/..'.'/../lib/Service/TagService.php',
53
+        'OCA\\Files\\Settings\\Admin' => __DIR__.'/..'.'/../lib/Settings/Admin.php',
54 54
     );
55 55
 
56 56
     public static function getInitializer(ClassLoader $loader)
57 57
     {
58
-        return \Closure::bind(function () use ($loader) {
58
+        return \Closure::bind(function() use ($loader) {
59 59
             $loader->prefixLengthsPsr4 = ComposerStaticInitFiles::$prefixLengthsPsr4;
60 60
             $loader->prefixDirsPsr4 = ComposerStaticInitFiles::$prefixDirsPsr4;
61 61
             $loader->classMap = ComposerStaticInitFiles::$classMap;
Please login to merge, or discard this patch.
apps/files/composer/composer/autoload_classmap.php 1 patch
Spacing   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -6,34 +6,34 @@
 block discarded – undo
6 6
 $baseDir = $vendorDir;
7 7
 
8 8
 return array(
9
-    'OCA\\Files\\Activity\\FavoriteProvider' => $baseDir . '/../lib/Activity/FavoriteProvider.php',
10
-    'OCA\\Files\\Activity\\Filter\\Favorites' => $baseDir . '/../lib/Activity/Filter/Favorites.php',
11
-    'OCA\\Files\\Activity\\Filter\\FileChanges' => $baseDir . '/../lib/Activity/Filter/FileChanges.php',
12
-    'OCA\\Files\\Activity\\Helper' => $baseDir . '/../lib/Activity/Helper.php',
13
-    'OCA\\Files\\Activity\\Provider' => $baseDir . '/../lib/Activity/Provider.php',
14
-    'OCA\\Files\\Activity\\Settings\\FavoriteAction' => $baseDir . '/../lib/Activity/Settings/FavoriteAction.php',
15
-    'OCA\\Files\\Activity\\Settings\\FileChanged' => $baseDir . '/../lib/Activity/Settings/FileChanged.php',
16
-    'OCA\\Files\\Activity\\Settings\\FileCreated' => $baseDir . '/../lib/Activity/Settings/FileCreated.php',
17
-    'OCA\\Files\\Activity\\Settings\\FileDeleted' => $baseDir . '/../lib/Activity/Settings/FileDeleted.php',
18
-    'OCA\\Files\\Activity\\Settings\\FileFavorite' => $baseDir . '/../lib/Activity/Settings/FileFavorite.php',
19
-    'OCA\\Files\\Activity\\Settings\\FileRestored' => $baseDir . '/../lib/Activity/Settings/FileRestored.php',
20
-    'OCA\\Files\\App' => $baseDir . '/../lib/App.php',
21
-    'OCA\\Files\\AppInfo\\Application' => $baseDir . '/../lib/AppInfo/Application.php',
22
-    'OCA\\Files\\BackgroundJob\\CleanupFileLocks' => $baseDir . '/../lib/BackgroundJob/CleanupFileLocks.php',
23
-    'OCA\\Files\\BackgroundJob\\DeleteOrphanedItems' => $baseDir . '/../lib/BackgroundJob/DeleteOrphanedItems.php',
24
-    'OCA\\Files\\BackgroundJob\\ScanFiles' => $baseDir . '/../lib/BackgroundJob/ScanFiles.php',
25
-    'OCA\\Files\\Capabilities' => $baseDir . '/../lib/Capabilities.php',
26
-    'OCA\\Files\\Collaboration\\Resources\\Listener' => $baseDir . '/../lib/Collaboration/Resources/Listener.php',
27
-    'OCA\\Files\\Collaboration\\Resources\\ResourceProvider' => $baseDir . '/../lib/Collaboration/Resources/ResourceProvider.php',
28
-    'OCA\\Files\\Command\\DeleteOrphanedFiles' => $baseDir . '/../lib/Command/DeleteOrphanedFiles.php',
29
-    'OCA\\Files\\Command\\Scan' => $baseDir . '/../lib/Command/Scan.php',
30
-    'OCA\\Files\\Command\\ScanAppData' => $baseDir . '/../lib/Command/ScanAppData.php',
31
-    'OCA\\Files\\Command\\TransferOwnership' => $baseDir . '/../lib/Command/TransferOwnership.php',
32
-    'OCA\\Files\\Controller\\AjaxController' => $baseDir . '/../lib/Controller/AjaxController.php',
33
-    'OCA\\Files\\Controller\\ApiController' => $baseDir . '/../lib/Controller/ApiController.php',
34
-    'OCA\\Files\\Controller\\SettingsController' => $baseDir . '/../lib/Controller/SettingsController.php',
35
-    'OCA\\Files\\Controller\\ViewController' => $baseDir . '/../lib/Controller/ViewController.php',
36
-    'OCA\\Files\\Helper' => $baseDir . '/../lib/Helper.php',
37
-    'OCA\\Files\\Service\\TagService' => $baseDir . '/../lib/Service/TagService.php',
38
-    'OCA\\Files\\Settings\\Admin' => $baseDir . '/../lib/Settings/Admin.php',
9
+    'OCA\\Files\\Activity\\FavoriteProvider' => $baseDir.'/../lib/Activity/FavoriteProvider.php',
10
+    'OCA\\Files\\Activity\\Filter\\Favorites' => $baseDir.'/../lib/Activity/Filter/Favorites.php',
11
+    'OCA\\Files\\Activity\\Filter\\FileChanges' => $baseDir.'/../lib/Activity/Filter/FileChanges.php',
12
+    'OCA\\Files\\Activity\\Helper' => $baseDir.'/../lib/Activity/Helper.php',
13
+    'OCA\\Files\\Activity\\Provider' => $baseDir.'/../lib/Activity/Provider.php',
14
+    'OCA\\Files\\Activity\\Settings\\FavoriteAction' => $baseDir.'/../lib/Activity/Settings/FavoriteAction.php',
15
+    'OCA\\Files\\Activity\\Settings\\FileChanged' => $baseDir.'/../lib/Activity/Settings/FileChanged.php',
16
+    'OCA\\Files\\Activity\\Settings\\FileCreated' => $baseDir.'/../lib/Activity/Settings/FileCreated.php',
17
+    'OCA\\Files\\Activity\\Settings\\FileDeleted' => $baseDir.'/../lib/Activity/Settings/FileDeleted.php',
18
+    'OCA\\Files\\Activity\\Settings\\FileFavorite' => $baseDir.'/../lib/Activity/Settings/FileFavorite.php',
19
+    'OCA\\Files\\Activity\\Settings\\FileRestored' => $baseDir.'/../lib/Activity/Settings/FileRestored.php',
20
+    'OCA\\Files\\App' => $baseDir.'/../lib/App.php',
21
+    'OCA\\Files\\AppInfo\\Application' => $baseDir.'/../lib/AppInfo/Application.php',
22
+    'OCA\\Files\\BackgroundJob\\CleanupFileLocks' => $baseDir.'/../lib/BackgroundJob/CleanupFileLocks.php',
23
+    'OCA\\Files\\BackgroundJob\\DeleteOrphanedItems' => $baseDir.'/../lib/BackgroundJob/DeleteOrphanedItems.php',
24
+    'OCA\\Files\\BackgroundJob\\ScanFiles' => $baseDir.'/../lib/BackgroundJob/ScanFiles.php',
25
+    'OCA\\Files\\Capabilities' => $baseDir.'/../lib/Capabilities.php',
26
+    'OCA\\Files\\Collaboration\\Resources\\Listener' => $baseDir.'/../lib/Collaboration/Resources/Listener.php',
27
+    'OCA\\Files\\Collaboration\\Resources\\ResourceProvider' => $baseDir.'/../lib/Collaboration/Resources/ResourceProvider.php',
28
+    'OCA\\Files\\Command\\DeleteOrphanedFiles' => $baseDir.'/../lib/Command/DeleteOrphanedFiles.php',
29
+    'OCA\\Files\\Command\\Scan' => $baseDir.'/../lib/Command/Scan.php',
30
+    'OCA\\Files\\Command\\ScanAppData' => $baseDir.'/../lib/Command/ScanAppData.php',
31
+    'OCA\\Files\\Command\\TransferOwnership' => $baseDir.'/../lib/Command/TransferOwnership.php',
32
+    'OCA\\Files\\Controller\\AjaxController' => $baseDir.'/../lib/Controller/AjaxController.php',
33
+    'OCA\\Files\\Controller\\ApiController' => $baseDir.'/../lib/Controller/ApiController.php',
34
+    'OCA\\Files\\Controller\\SettingsController' => $baseDir.'/../lib/Controller/SettingsController.php',
35
+    'OCA\\Files\\Controller\\ViewController' => $baseDir.'/../lib/Controller/ViewController.php',
36
+    'OCA\\Files\\Helper' => $baseDir.'/../lib/Helper.php',
37
+    'OCA\\Files\\Service\\TagService' => $baseDir.'/../lib/Service/TagService.php',
38
+    'OCA\\Files\\Settings\\Admin' => $baseDir.'/../lib/Settings/Admin.php',
39 39
 );
Please login to merge, or discard this patch.
lib/private/Server.php 1 patch
Spacing   +115 added lines, -115 removed lines patch added patch discarded remove patch
@@ -184,7 +184,7 @@  discard block
 block discarded – undo
184 184
 		// To find out if we are running from CLI or not
185 185
 		$this->registerParameter('isCLI', \OC::$CLI);
186 186
 
187
-		$this->registerService(\OCP\IServerContainer::class, function (IServerContainer $c) {
187
+		$this->registerService(\OCP\IServerContainer::class, function(IServerContainer $c) {
188 188
 			return $c;
189 189
 		});
190 190
 
@@ -203,7 +203,7 @@  discard block
 block discarded – undo
203 203
 		$this->registerAlias(IActionFactory::class, ActionFactory::class);
204 204
 
205 205
 
206
-		$this->registerService(\OCP\IPreview::class, function (Server $c) {
206
+		$this->registerService(\OCP\IPreview::class, function(Server $c) {
207 207
 			return new PreviewManager(
208 208
 				$c->getConfig(),
209 209
 				$c->getRootFolder(),
@@ -214,13 +214,13 @@  discard block
 block discarded – undo
214 214
 		});
215 215
 		$this->registerAlias('PreviewManager', \OCP\IPreview::class);
216 216
 
217
-		$this->registerService(\OC\Preview\Watcher::class, function (Server $c) {
217
+		$this->registerService(\OC\Preview\Watcher::class, function(Server $c) {
218 218
 			return new \OC\Preview\Watcher(
219 219
 				$c->getAppDataDir('preview')
220 220
 			);
221 221
 		});
222 222
 
223
-		$this->registerService(\OCP\Encryption\IManager::class, function (Server $c) {
223
+		$this->registerService(\OCP\Encryption\IManager::class, function(Server $c) {
224 224
 			$view = new View();
225 225
 			$util = new Encryption\Util(
226 226
 				$view,
@@ -239,7 +239,7 @@  discard block
 block discarded – undo
239 239
 		});
240 240
 		$this->registerAlias('EncryptionManager', \OCP\Encryption\IManager::class);
241 241
 
242
-		$this->registerService('EncryptionFileHelper', function (Server $c) {
242
+		$this->registerService('EncryptionFileHelper', function(Server $c) {
243 243
 			$util = new Encryption\Util(
244 244
 				new View(),
245 245
 				$c->getUserManager(),
@@ -253,7 +253,7 @@  discard block
 block discarded – undo
253 253
 			);
254 254
 		});
255 255
 
256
-		$this->registerService('EncryptionKeyStorage', function (Server $c) {
256
+		$this->registerService('EncryptionKeyStorage', function(Server $c) {
257 257
 			$view = new View();
258 258
 			$util = new Encryption\Util(
259 259
 				$view,
@@ -264,30 +264,30 @@  discard block
 block discarded – undo
264 264
 
265 265
 			return new Encryption\Keys\Storage($view, $util);
266 266
 		});
267
-		$this->registerService('TagMapper', function (Server $c) {
267
+		$this->registerService('TagMapper', function(Server $c) {
268 268
 			return new TagMapper($c->getDatabaseConnection());
269 269
 		});
270 270
 
271
-		$this->registerService(\OCP\ITagManager::class, function (Server $c) {
271
+		$this->registerService(\OCP\ITagManager::class, function(Server $c) {
272 272
 			$tagMapper = $c->query('TagMapper');
273 273
 			return new TagManager($tagMapper, $c->getUserSession());
274 274
 		});
275 275
 		$this->registerAlias('TagManager', \OCP\ITagManager::class);
276 276
 
277
-		$this->registerService('SystemTagManagerFactory', function (Server $c) {
277
+		$this->registerService('SystemTagManagerFactory', function(Server $c) {
278 278
 			$config = $c->getConfig();
279 279
 			$factoryClass = $config->getSystemValue('systemtags.managerFactory', SystemTagManagerFactory::class);
280 280
 			return new $factoryClass($this);
281 281
 		});
282
-		$this->registerService(\OCP\SystemTag\ISystemTagManager::class, function (Server $c) {
282
+		$this->registerService(\OCP\SystemTag\ISystemTagManager::class, function(Server $c) {
283 283
 			return $c->query('SystemTagManagerFactory')->getManager();
284 284
 		});
285 285
 		$this->registerAlias('SystemTagManager', \OCP\SystemTag\ISystemTagManager::class);
286 286
 
287
-		$this->registerService(\OCP\SystemTag\ISystemTagObjectMapper::class, function (Server $c) {
287
+		$this->registerService(\OCP\SystemTag\ISystemTagObjectMapper::class, function(Server $c) {
288 288
 			return $c->query('SystemTagManagerFactory')->getObjectMapper();
289 289
 		});
290
-		$this->registerService('RootFolder', function (Server $c) {
290
+		$this->registerService('RootFolder', function(Server $c) {
291 291
 			$manager = \OC\Files\Filesystem::getMountManager(null);
292 292
 			$view = new View();
293 293
 			$root = new Root(
@@ -308,37 +308,37 @@  discard block
 block discarded – undo
308 308
 		});
309 309
 		$this->registerAlias('SystemTagObjectMapper', \OCP\SystemTag\ISystemTagObjectMapper::class);
310 310
 
311
-		$this->registerService(\OCP\Files\IRootFolder::class, function (Server $c) {
312
-			return new LazyRoot(function () use ($c) {
311
+		$this->registerService(\OCP\Files\IRootFolder::class, function(Server $c) {
312
+			return new LazyRoot(function() use ($c) {
313 313
 				return $c->query('RootFolder');
314 314
 			});
315 315
 		});
316 316
 		$this->registerAlias('LazyRootFolder', \OCP\Files\IRootFolder::class);
317 317
 
318
-		$this->registerService(\OC\User\Manager::class, function (Server $c) {
318
+		$this->registerService(\OC\User\Manager::class, function(Server $c) {
319 319
 			return new \OC\User\Manager($c->getConfig(), $c->getEventDispatcher());
320 320
 		});
321 321
 		$this->registerAlias('UserManager', \OC\User\Manager::class);
322 322
 		$this->registerAlias(\OCP\IUserManager::class, \OC\User\Manager::class);
323 323
 
324
-		$this->registerService(\OCP\IGroupManager::class, function (Server $c) {
324
+		$this->registerService(\OCP\IGroupManager::class, function(Server $c) {
325 325
 			$groupManager = new \OC\Group\Manager($this->getUserManager(), $c->getEventDispatcher(), $this->getLogger());
326
-			$groupManager->listen('\OC\Group', 'preCreate', function ($gid) {
326
+			$groupManager->listen('\OC\Group', 'preCreate', function($gid) {
327 327
 				\OC_Hook::emit('OC_Group', 'pre_createGroup', array('run' => true, 'gid' => $gid));
328 328
 			});
329
-			$groupManager->listen('\OC\Group', 'postCreate', function (\OC\Group\Group $gid) {
329
+			$groupManager->listen('\OC\Group', 'postCreate', function(\OC\Group\Group $gid) {
330 330
 				\OC_Hook::emit('OC_User', 'post_createGroup', array('gid' => $gid->getGID()));
331 331
 			});
332
-			$groupManager->listen('\OC\Group', 'preDelete', function (\OC\Group\Group $group) {
332
+			$groupManager->listen('\OC\Group', 'preDelete', function(\OC\Group\Group $group) {
333 333
 				\OC_Hook::emit('OC_Group', 'pre_deleteGroup', array('run' => true, 'gid' => $group->getGID()));
334 334
 			});
335
-			$groupManager->listen('\OC\Group', 'postDelete', function (\OC\Group\Group $group) {
335
+			$groupManager->listen('\OC\Group', 'postDelete', function(\OC\Group\Group $group) {
336 336
 				\OC_Hook::emit('OC_User', 'post_deleteGroup', array('gid' => $group->getGID()));
337 337
 			});
338
-			$groupManager->listen('\OC\Group', 'preAddUser', function (\OC\Group\Group $group, \OC\User\User $user) {
338
+			$groupManager->listen('\OC\Group', 'preAddUser', function(\OC\Group\Group $group, \OC\User\User $user) {
339 339
 				\OC_Hook::emit('OC_Group', 'pre_addToGroup', array('run' => true, 'uid' => $user->getUID(), 'gid' => $group->getGID()));
340 340
 			});
341
-			$groupManager->listen('\OC\Group', 'postAddUser', function (\OC\Group\Group $group, \OC\User\User $user) {
341
+			$groupManager->listen('\OC\Group', 'postAddUser', function(\OC\Group\Group $group, \OC\User\User $user) {
342 342
 				\OC_Hook::emit('OC_Group', 'post_addToGroup', array('uid' => $user->getUID(), 'gid' => $group->getGID()));
343 343
 				//Minimal fix to keep it backward compatible TODO: clean up all the GroupManager hooks
344 344
 				\OC_Hook::emit('OC_User', 'post_addToGroup', array('uid' => $user->getUID(), 'gid' => $group->getGID()));
@@ -347,7 +347,7 @@  discard block
 block discarded – undo
347 347
 		});
348 348
 		$this->registerAlias('GroupManager', \OCP\IGroupManager::class);
349 349
 
350
-		$this->registerService(Store::class, function (Server $c) {
350
+		$this->registerService(Store::class, function(Server $c) {
351 351
 			$session = $c->getSession();
352 352
 			if (\OC::$server->getSystemConfig()->getValue('installed', false)) {
353 353
 				$tokenProvider = $c->query(IProvider::class);
@@ -358,13 +358,13 @@  discard block
 block discarded – undo
358 358
 			return new Store($session, $logger, $tokenProvider);
359 359
 		});
360 360
 		$this->registerAlias(IStore::class, Store::class);
361
-		$this->registerService(Authentication\Token\DefaultTokenMapper::class, function (Server $c) {
361
+		$this->registerService(Authentication\Token\DefaultTokenMapper::class, function(Server $c) {
362 362
 			$dbConnection = $c->getDatabaseConnection();
363 363
 			return new Authentication\Token\DefaultTokenMapper($dbConnection);
364 364
 		});
365 365
 		$this->registerAlias(IProvider::class, Authentication\Token\Manager::class);
366 366
 
367
-		$this->registerService(\OC\User\Session::class, function (Server $c) {
367
+		$this->registerService(\OC\User\Session::class, function(Server $c) {
368 368
 			$manager = $c->getUserManager();
369 369
 			$session = new \OC\Session\Memory('');
370 370
 			$timeFactory = new TimeFactory();
@@ -388,45 +388,45 @@  discard block
 block discarded – undo
388 388
 				$c->getLockdownManager(),
389 389
 				$c->getLogger()
390 390
 			);
391
-			$userSession->listen('\OC\User', 'preCreateUser', function ($uid, $password) {
391
+			$userSession->listen('\OC\User', 'preCreateUser', function($uid, $password) {
392 392
 				\OC_Hook::emit('OC_User', 'pre_createUser', array('run' => true, 'uid' => $uid, 'password' => $password));
393 393
 			});
394
-			$userSession->listen('\OC\User', 'postCreateUser', function ($user, $password) {
394
+			$userSession->listen('\OC\User', 'postCreateUser', function($user, $password) {
395 395
 				/** @var $user \OC\User\User */
396 396
 				\OC_Hook::emit('OC_User', 'post_createUser', array('uid' => $user->getUID(), 'password' => $password));
397 397
 			});
398
-			$userSession->listen('\OC\User', 'preDelete', function ($user) use ($dispatcher) {
398
+			$userSession->listen('\OC\User', 'preDelete', function($user) use ($dispatcher) {
399 399
 				/** @var $user \OC\User\User */
400 400
 				\OC_Hook::emit('OC_User', 'pre_deleteUser', array('run' => true, 'uid' => $user->getUID()));
401 401
 				$dispatcher->dispatch('OCP\IUser::preDelete', new GenericEvent($user));
402 402
 			});
403
-			$userSession->listen('\OC\User', 'postDelete', function ($user) {
403
+			$userSession->listen('\OC\User', 'postDelete', function($user) {
404 404
 				/** @var $user \OC\User\User */
405 405
 				\OC_Hook::emit('OC_User', 'post_deleteUser', array('uid' => $user->getUID()));
406 406
 			});
407
-			$userSession->listen('\OC\User', 'preSetPassword', function ($user, $password, $recoveryPassword) {
407
+			$userSession->listen('\OC\User', 'preSetPassword', function($user, $password, $recoveryPassword) {
408 408
 				/** @var $user \OC\User\User */
409 409
 				\OC_Hook::emit('OC_User', 'pre_setPassword', array('run' => true, 'uid' => $user->getUID(), 'password' => $password, 'recoveryPassword' => $recoveryPassword));
410 410
 			});
411
-			$userSession->listen('\OC\User', 'postSetPassword', function ($user, $password, $recoveryPassword) {
411
+			$userSession->listen('\OC\User', 'postSetPassword', function($user, $password, $recoveryPassword) {
412 412
 				/** @var $user \OC\User\User */
413 413
 				\OC_Hook::emit('OC_User', 'post_setPassword', array('run' => true, 'uid' => $user->getUID(), 'password' => $password, 'recoveryPassword' => $recoveryPassword));
414 414
 			});
415
-			$userSession->listen('\OC\User', 'preLogin', function ($uid, $password) {
415
+			$userSession->listen('\OC\User', 'preLogin', function($uid, $password) {
416 416
 				\OC_Hook::emit('OC_User', 'pre_login', array('run' => true, 'uid' => $uid, 'password' => $password));
417 417
 			});
418
-			$userSession->listen('\OC\User', 'postLogin', function ($user, $password, $isTokenLogin) {
418
+			$userSession->listen('\OC\User', 'postLogin', function($user, $password, $isTokenLogin) {
419 419
 				/** @var $user \OC\User\User */
420 420
 				\OC_Hook::emit('OC_User', 'post_login', array('run' => true, 'uid' => $user->getUID(), 'password' => $password, 'isTokenLogin' => $isTokenLogin));
421 421
 			});
422
-			$userSession->listen('\OC\User', 'postRememberedLogin', function ($user, $password) {
422
+			$userSession->listen('\OC\User', 'postRememberedLogin', function($user, $password) {
423 423
 				/** @var $user \OC\User\User */
424 424
 				\OC_Hook::emit('OC_User', 'post_login', array('run' => true, 'uid' => $user->getUID(), 'password' => $password));
425 425
 			});
426
-			$userSession->listen('\OC\User', 'logout', function () {
426
+			$userSession->listen('\OC\User', 'logout', function() {
427 427
 				\OC_Hook::emit('OC_User', 'logout', array());
428 428
 			});
429
-			$userSession->listen('\OC\User', 'changeUser', function ($user, $feature, $value, $oldValue) use ($dispatcher) {
429
+			$userSession->listen('\OC\User', 'changeUser', function($user, $feature, $value, $oldValue) use ($dispatcher) {
430 430
 				/** @var $user \OC\User\User */
431 431
 				\OC_Hook::emit('OC_User', 'changeUser', array('run' => true, 'user' => $user, 'feature' => $feature, 'value' => $value, 'old_value' => $oldValue));
432 432
 				$dispatcher->dispatch('OCP\IUser::changeUser', new GenericEvent($user, ['feature' => $feature, 'oldValue' => $oldValue, 'value' => $value]));
@@ -441,7 +441,7 @@  discard block
 block discarded – undo
441 441
 		$this->registerAlias(\OCP\INavigationManager::class, \OC\NavigationManager::class);
442 442
 		$this->registerAlias('NavigationManager', \OCP\INavigationManager::class);
443 443
 
444
-		$this->registerService(\OC\AllConfig::class, function (Server $c) {
444
+		$this->registerService(\OC\AllConfig::class, function(Server $c) {
445 445
 			return new \OC\AllConfig(
446 446
 				$c->getSystemConfig()
447 447
 			);
@@ -449,17 +449,17 @@  discard block
 block discarded – undo
449 449
 		$this->registerAlias('AllConfig', \OC\AllConfig::class);
450 450
 		$this->registerAlias(\OCP\IConfig::class, \OC\AllConfig::class);
451 451
 
452
-		$this->registerService('SystemConfig', function ($c) use ($config) {
452
+		$this->registerService('SystemConfig', function($c) use ($config) {
453 453
 			return new \OC\SystemConfig($config);
454 454
 		});
455 455
 
456
-		$this->registerService(\OC\AppConfig::class, function (Server $c) {
456
+		$this->registerService(\OC\AppConfig::class, function(Server $c) {
457 457
 			return new \OC\AppConfig($c->getDatabaseConnection());
458 458
 		});
459 459
 		$this->registerAlias('AppConfig', \OC\AppConfig::class);
460 460
 		$this->registerAlias(\OCP\IAppConfig::class, \OC\AppConfig::class);
461 461
 
462
-		$this->registerService(\OCP\L10N\IFactory::class, function (Server $c) {
462
+		$this->registerService(\OCP\L10N\IFactory::class, function(Server $c) {
463 463
 			return new \OC\L10N\Factory(
464 464
 				$c->getConfig(),
465 465
 				$c->getRequest(),
@@ -469,7 +469,7 @@  discard block
 block discarded – undo
469 469
 		});
470 470
 		$this->registerAlias('L10NFactory', \OCP\L10N\IFactory::class);
471 471
 
472
-		$this->registerService(\OCP\IURLGenerator::class, function (Server $c) {
472
+		$this->registerService(\OCP\IURLGenerator::class, function(Server $c) {
473 473
 			$config = $c->getConfig();
474 474
 			$cacheFactory = $c->getMemCacheFactory();
475 475
 			$request = $c->getRequest();
@@ -484,12 +484,12 @@  discard block
 block discarded – undo
484 484
 		$this->registerAlias('AppFetcher', AppFetcher::class);
485 485
 		$this->registerAlias('CategoryFetcher', CategoryFetcher::class);
486 486
 
487
-		$this->registerService(\OCP\ICache::class, function ($c) {
487
+		$this->registerService(\OCP\ICache::class, function($c) {
488 488
 			return new Cache\File();
489 489
 		});
490 490
 		$this->registerAlias('UserCache', \OCP\ICache::class);
491 491
 
492
-		$this->registerService(Factory::class, function (Server $c) {
492
+		$this->registerService(Factory::class, function(Server $c) {
493 493
 
494 494
 			$arrayCacheFactory = new \OC\Memcache\Factory('', $c->getLogger(),
495 495
 				ArrayCache::class,
@@ -506,7 +506,7 @@  discard block
 block discarded – undo
506 506
 				$version = implode(',', $v);
507 507
 				$instanceId = \OC_Util::getInstanceId();
508 508
 				$path = \OC::$SERVERROOT;
509
-				$prefix = md5($instanceId . '-' . $version . '-' . $path);
509
+				$prefix = md5($instanceId.'-'.$version.'-'.$path);
510 510
 				return new \OC\Memcache\Factory($prefix, $c->getLogger(),
511 511
 					$config->getSystemValue('memcache.local', null),
512 512
 					$config->getSystemValue('memcache.distributed', null),
@@ -519,12 +519,12 @@  discard block
 block discarded – undo
519 519
 		$this->registerAlias('MemCacheFactory', Factory::class);
520 520
 		$this->registerAlias(ICacheFactory::class, Factory::class);
521 521
 
522
-		$this->registerService('RedisFactory', function (Server $c) {
522
+		$this->registerService('RedisFactory', function(Server $c) {
523 523
 			$systemConfig = $c->getSystemConfig();
524 524
 			return new RedisFactory($systemConfig);
525 525
 		});
526 526
 
527
-		$this->registerService(\OCP\Activity\IManager::class, function (Server $c) {
527
+		$this->registerService(\OCP\Activity\IManager::class, function(Server $c) {
528 528
 			return new \OC\Activity\Manager(
529 529
 				$c->getRequest(),
530 530
 				$c->getUserSession(),
@@ -534,7 +534,7 @@  discard block
 block discarded – undo
534 534
 		});
535 535
 		$this->registerAlias('ActivityManager', \OCP\Activity\IManager::class);
536 536
 
537
-		$this->registerService(\OCP\Activity\IEventMerger::class, function (Server $c) {
537
+		$this->registerService(\OCP\Activity\IEventMerger::class, function(Server $c) {
538 538
 			return new \OC\Activity\EventMerger(
539 539
 				$c->getL10N('lib')
540 540
 			);
@@ -555,7 +555,7 @@  discard block
 block discarded – undo
555 555
 
556 556
 		$this->registerAlias(\OCP\Support\CrashReport\IRegistry::class, \OC\Support\CrashReport\Registry::class);
557 557
 
558
-		$this->registerService(\OC\Log::class, function (Server $c) {
558
+		$this->registerService(\OC\Log::class, function(Server $c) {
559 559
 			$logType = $c->query('AllConfig')->getSystemValue('log_type', 'file');
560 560
 			$factory = new LogFactory($c, $this->getSystemConfig());
561 561
 			$logger = $factory->get($logType);
@@ -566,11 +566,11 @@  discard block
 block discarded – undo
566 566
 		$this->registerAlias(\OCP\ILogger::class, \OC\Log::class);
567 567
 		$this->registerAlias('Logger', \OC\Log::class);
568 568
 
569
-		$this->registerService(ILogFactory::class, function (Server $c) {
569
+		$this->registerService(ILogFactory::class, function(Server $c) {
570 570
 			return new LogFactory($c, $this->getSystemConfig());
571 571
 		});
572 572
 
573
-		$this->registerService(\OCP\BackgroundJob\IJobList::class, function (Server $c) {
573
+		$this->registerService(\OCP\BackgroundJob\IJobList::class, function(Server $c) {
574 574
 			$config = $c->getConfig();
575 575
 			return new \OC\BackgroundJob\JobList(
576 576
 				$c->getDatabaseConnection(),
@@ -580,7 +580,7 @@  discard block
 block discarded – undo
580 580
 		});
581 581
 		$this->registerAlias('JobList', \OCP\BackgroundJob\IJobList::class);
582 582
 
583
-		$this->registerService(\OCP\Route\IRouter::class, function (Server $c) {
583
+		$this->registerService(\OCP\Route\IRouter::class, function(Server $c) {
584 584
 			$cacheFactory = $c->getMemCacheFactory();
585 585
 			$logger = $c->getLogger();
586 586
 			if ($cacheFactory->isLocalCacheAvailable()) {
@@ -592,12 +592,12 @@  discard block
 block discarded – undo
592 592
 		});
593 593
 		$this->registerAlias('Router', \OCP\Route\IRouter::class);
594 594
 
595
-		$this->registerService(\OCP\ISearch::class, function ($c) {
595
+		$this->registerService(\OCP\ISearch::class, function($c) {
596 596
 			return new Search();
597 597
 		});
598 598
 		$this->registerAlias('Search', \OCP\ISearch::class);
599 599
 
600
-		$this->registerService(\OC\Security\RateLimiting\Limiter::class, function (Server $c) {
600
+		$this->registerService(\OC\Security\RateLimiting\Limiter::class, function(Server $c) {
601 601
 			return new \OC\Security\RateLimiting\Limiter(
602 602
 				$this->getUserSession(),
603 603
 				$this->getRequest(),
@@ -605,34 +605,34 @@  discard block
 block discarded – undo
605 605
 				$c->query(\OC\Security\RateLimiting\Backend\IBackend::class)
606 606
 			);
607 607
 		});
608
-		$this->registerService(\OC\Security\RateLimiting\Backend\IBackend::class, function ($c) {
608
+		$this->registerService(\OC\Security\RateLimiting\Backend\IBackend::class, function($c) {
609 609
 			return new \OC\Security\RateLimiting\Backend\MemoryCache(
610 610
 				$this->getMemCacheFactory(),
611 611
 				new \OC\AppFramework\Utility\TimeFactory()
612 612
 			);
613 613
 		});
614 614
 
615
-		$this->registerService(\OCP\Security\ISecureRandom::class, function ($c) {
615
+		$this->registerService(\OCP\Security\ISecureRandom::class, function($c) {
616 616
 			return new SecureRandom();
617 617
 		});
618 618
 		$this->registerAlias('SecureRandom', \OCP\Security\ISecureRandom::class);
619 619
 
620
-		$this->registerService(\OCP\Security\ICrypto::class, function (Server $c) {
620
+		$this->registerService(\OCP\Security\ICrypto::class, function(Server $c) {
621 621
 			return new Crypto($c->getConfig(), $c->getSecureRandom());
622 622
 		});
623 623
 		$this->registerAlias('Crypto', \OCP\Security\ICrypto::class);
624 624
 
625
-		$this->registerService(\OCP\Security\IHasher::class, function (Server $c) {
625
+		$this->registerService(\OCP\Security\IHasher::class, function(Server $c) {
626 626
 			return new Hasher($c->getConfig());
627 627
 		});
628 628
 		$this->registerAlias('Hasher', \OCP\Security\IHasher::class);
629 629
 
630
-		$this->registerService(\OCP\Security\ICredentialsManager::class, function (Server $c) {
630
+		$this->registerService(\OCP\Security\ICredentialsManager::class, function(Server $c) {
631 631
 			return new CredentialsManager($c->getCrypto(), $c->getDatabaseConnection());
632 632
 		});
633 633
 		$this->registerAlias('CredentialsManager', \OCP\Security\ICredentialsManager::class);
634 634
 
635
-		$this->registerService(IDBConnection::class, function (Server $c) {
635
+		$this->registerService(IDBConnection::class, function(Server $c) {
636 636
 			$systemConfig = $c->getSystemConfig();
637 637
 			$factory = new \OC\DB\ConnectionFactory($systemConfig);
638 638
 			$type = $systemConfig->getValue('dbtype', 'sqlite');
@@ -647,7 +647,7 @@  discard block
 block discarded – undo
647 647
 		$this->registerAlias('DatabaseConnection', IDBConnection::class);
648 648
 
649 649
 
650
-		$this->registerService(\OCP\Http\Client\IClientService::class, function (Server $c) {
650
+		$this->registerService(\OCP\Http\Client\IClientService::class, function(Server $c) {
651 651
 			$user = \OC_User::getUser();
652 652
 			$uid = $user ? $user : null;
653 653
 			return new ClientService(
@@ -662,7 +662,7 @@  discard block
 block discarded – undo
662 662
 			);
663 663
 		});
664 664
 		$this->registerAlias('HttpClientService', \OCP\Http\Client\IClientService::class);
665
-		$this->registerService(\OCP\Diagnostics\IEventLogger::class, function (Server $c) {
665
+		$this->registerService(\OCP\Diagnostics\IEventLogger::class, function(Server $c) {
666 666
 			$eventLogger = new EventLogger();
667 667
 			if ($c->getSystemConfig()->getValue('debug', false)) {
668 668
 				// In debug mode, module is being activated by default
@@ -672,7 +672,7 @@  discard block
 block discarded – undo
672 672
 		});
673 673
 		$this->registerAlias('EventLogger', \OCP\Diagnostics\IEventLogger::class);
674 674
 
675
-		$this->registerService(\OCP\Diagnostics\IQueryLogger::class, function (Server $c) {
675
+		$this->registerService(\OCP\Diagnostics\IQueryLogger::class, function(Server $c) {
676 676
 			$queryLogger = new QueryLogger();
677 677
 			if ($c->getSystemConfig()->getValue('debug', false)) {
678 678
 				// In debug mode, module is being activated by default
@@ -682,7 +682,7 @@  discard block
 block discarded – undo
682 682
 		});
683 683
 		$this->registerAlias('QueryLogger', \OCP\Diagnostics\IQueryLogger::class);
684 684
 
685
-		$this->registerService(TempManager::class, function (Server $c) {
685
+		$this->registerService(TempManager::class, function(Server $c) {
686 686
 			return new TempManager(
687 687
 				$c->getLogger(),
688 688
 				$c->getConfig()
@@ -691,7 +691,7 @@  discard block
 block discarded – undo
691 691
 		$this->registerAlias('TempManager', TempManager::class);
692 692
 		$this->registerAlias(ITempManager::class, TempManager::class);
693 693
 
694
-		$this->registerService(AppManager::class, function (Server $c) {
694
+		$this->registerService(AppManager::class, function(Server $c) {
695 695
 			return new \OC\App\AppManager(
696 696
 				$c->getUserSession(),
697 697
 				$c->query(\OC\AppConfig::class),
@@ -703,7 +703,7 @@  discard block
 block discarded – undo
703 703
 		$this->registerAlias('AppManager', AppManager::class);
704 704
 		$this->registerAlias(IAppManager::class, AppManager::class);
705 705
 
706
-		$this->registerService(\OCP\IDateTimeZone::class, function (Server $c) {
706
+		$this->registerService(\OCP\IDateTimeZone::class, function(Server $c) {
707 707
 			return new DateTimeZone(
708 708
 				$c->getConfig(),
709 709
 				$c->getSession()
@@ -711,7 +711,7 @@  discard block
 block discarded – undo
711 711
 		});
712 712
 		$this->registerAlias('DateTimeZone', \OCP\IDateTimeZone::class);
713 713
 
714
-		$this->registerService(\OCP\IDateTimeFormatter::class, function (Server $c) {
714
+		$this->registerService(\OCP\IDateTimeFormatter::class, function(Server $c) {
715 715
 			$language = $c->getConfig()->getUserValue($c->getSession()->get('user_id'), 'core', 'lang', null);
716 716
 
717 717
 			return new DateTimeFormatter(
@@ -721,7 +721,7 @@  discard block
 block discarded – undo
721 721
 		});
722 722
 		$this->registerAlias('DateTimeFormatter', \OCP\IDateTimeFormatter::class);
723 723
 
724
-		$this->registerService(\OCP\Files\Config\IUserMountCache::class, function (Server $c) {
724
+		$this->registerService(\OCP\Files\Config\IUserMountCache::class, function(Server $c) {
725 725
 			$mountCache = new UserMountCache($c->getDatabaseConnection(), $c->getUserManager(), $c->getLogger());
726 726
 			$listener = new UserMountCacheListener($mountCache);
727 727
 			$listener->listen($c->getUserManager());
@@ -729,7 +729,7 @@  discard block
 block discarded – undo
729 729
 		});
730 730
 		$this->registerAlias('UserMountCache', \OCP\Files\Config\IUserMountCache::class);
731 731
 
732
-		$this->registerService(\OCP\Files\Config\IMountProviderCollection::class, function (Server $c) {
732
+		$this->registerService(\OCP\Files\Config\IMountProviderCollection::class, function(Server $c) {
733 733
 			$loader = \OC\Files\Filesystem::getLoader();
734 734
 			$mountCache = $c->query('UserMountCache');
735 735
 			$manager = new \OC\Files\Config\MountProviderCollection($loader, $mountCache);
@@ -745,10 +745,10 @@  discard block
 block discarded – undo
745 745
 		});
746 746
 		$this->registerAlias('MountConfigManager', \OCP\Files\Config\IMountProviderCollection::class);
747 747
 
748
-		$this->registerService('IniWrapper', function ($c) {
748
+		$this->registerService('IniWrapper', function($c) {
749 749
 			return new IniGetWrapper();
750 750
 		});
751
-		$this->registerService('AsyncCommandBus', function (Server $c) {
751
+		$this->registerService('AsyncCommandBus', function(Server $c) {
752 752
 			$busClass = $c->getConfig()->getSystemValue('commandbus');
753 753
 			if ($busClass) {
754 754
 				list($app, $class) = explode('::', $busClass, 2);
@@ -763,10 +763,10 @@  discard block
 block discarded – undo
763 763
 				return new CronBus($jobList);
764 764
 			}
765 765
 		});
766
-		$this->registerService('TrustedDomainHelper', function ($c) {
766
+		$this->registerService('TrustedDomainHelper', function($c) {
767 767
 			return new TrustedDomainHelper($this->getConfig());
768 768
 		});
769
-		$this->registerService(Throttler::class, function (Server $c) {
769
+		$this->registerService(Throttler::class, function(Server $c) {
770 770
 			return new Throttler(
771 771
 				$c->getDatabaseConnection(),
772 772
 				new TimeFactory(),
@@ -775,7 +775,7 @@  discard block
 block discarded – undo
775 775
 			);
776 776
 		});
777 777
 		$this->registerAlias('Throttler', Throttler::class);
778
-		$this->registerService('IntegrityCodeChecker', function (Server $c) {
778
+		$this->registerService('IntegrityCodeChecker', function(Server $c) {
779 779
 			// IConfig and IAppManager requires a working database. This code
780 780
 			// might however be called when ownCloud is not yet setup.
781 781
 			if (\OC::$server->getSystemConfig()->getValue('installed', false)) {
@@ -796,7 +796,7 @@  discard block
 block discarded – undo
796 796
 				$c->getTempManager()
797 797
 			);
798 798
 		});
799
-		$this->registerService(\OCP\IRequest::class, function ($c) {
799
+		$this->registerService(\OCP\IRequest::class, function($c) {
800 800
 			if (isset($this['urlParams'])) {
801 801
 				$urlParams = $this['urlParams'];
802 802
 			} else {
@@ -832,7 +832,7 @@  discard block
 block discarded – undo
832 832
 		});
833 833
 		$this->registerAlias('Request', \OCP\IRequest::class);
834 834
 
835
-		$this->registerService(\OCP\Mail\IMailer::class, function (Server $c) {
835
+		$this->registerService(\OCP\Mail\IMailer::class, function(Server $c) {
836 836
 			return new Mailer(
837 837
 				$c->getConfig(),
838 838
 				$c->getLogger(),
@@ -843,7 +843,7 @@  discard block
 block discarded – undo
843 843
 		});
844 844
 		$this->registerAlias('Mailer', \OCP\Mail\IMailer::class);
845 845
 
846
-		$this->registerService('LDAPProvider', function (Server $c) {
846
+		$this->registerService('LDAPProvider', function(Server $c) {
847 847
 			$config = $c->getConfig();
848 848
 			$factoryClass = $config->getSystemValue('ldapProviderFactory', null);
849 849
 			if (is_null($factoryClass)) {
@@ -853,7 +853,7 @@  discard block
 block discarded – undo
853 853
 			$factory = new $factoryClass($this);
854 854
 			return $factory->getLDAPProvider();
855 855
 		});
856
-		$this->registerService(ILockingProvider::class, function (Server $c) {
856
+		$this->registerService(ILockingProvider::class, function(Server $c) {
857 857
 			$ini = $c->getIniWrapper();
858 858
 			$config = $c->getConfig();
859 859
 			$ttl = $config->getSystemValue('filelocking.ttl', max(3600, $ini->getNumeric('max_execution_time')));
@@ -876,49 +876,49 @@  discard block
 block discarded – undo
876 876
 		});
877 877
 		$this->registerAlias('LockingProvider', ILockingProvider::class);
878 878
 
879
-		$this->registerService(\OCP\Files\Mount\IMountManager::class, function () {
879
+		$this->registerService(\OCP\Files\Mount\IMountManager::class, function() {
880 880
 			return new \OC\Files\Mount\Manager();
881 881
 		});
882 882
 		$this->registerAlias('MountManager', \OCP\Files\Mount\IMountManager::class);
883 883
 
884
-		$this->registerService(\OCP\Files\IMimeTypeDetector::class, function (Server $c) {
884
+		$this->registerService(\OCP\Files\IMimeTypeDetector::class, function(Server $c) {
885 885
 			return new \OC\Files\Type\Detection(
886 886
 				$c->getURLGenerator(),
887 887
 				\OC::$configDir,
888
-				\OC::$SERVERROOT . '/resources/config/'
888
+				\OC::$SERVERROOT.'/resources/config/'
889 889
 			);
890 890
 		});
891 891
 		$this->registerAlias('MimeTypeDetector', \OCP\Files\IMimeTypeDetector::class);
892 892
 
893
-		$this->registerService(\OCP\Files\IMimeTypeLoader::class, function (Server $c) {
893
+		$this->registerService(\OCP\Files\IMimeTypeLoader::class, function(Server $c) {
894 894
 			return new \OC\Files\Type\Loader(
895 895
 				$c->getDatabaseConnection()
896 896
 			);
897 897
 		});
898 898
 		$this->registerAlias('MimeTypeLoader', \OCP\Files\IMimeTypeLoader::class);
899
-		$this->registerService(BundleFetcher::class, function () {
899
+		$this->registerService(BundleFetcher::class, function() {
900 900
 			return new BundleFetcher($this->getL10N('lib'));
901 901
 		});
902
-		$this->registerService(\OCP\Notification\IManager::class, function (Server $c) {
902
+		$this->registerService(\OCP\Notification\IManager::class, function(Server $c) {
903 903
 			return new Manager(
904 904
 				$c->query(IValidator::class)
905 905
 			);
906 906
 		});
907 907
 		$this->registerAlias('NotificationManager', \OCP\Notification\IManager::class);
908 908
 
909
-		$this->registerService(\OC\CapabilitiesManager::class, function (Server $c) {
909
+		$this->registerService(\OC\CapabilitiesManager::class, function(Server $c) {
910 910
 			$manager = new \OC\CapabilitiesManager($c->getLogger());
911
-			$manager->registerCapability(function () use ($c) {
911
+			$manager->registerCapability(function() use ($c) {
912 912
 				return new \OC\OCS\CoreCapabilities($c->getConfig());
913 913
 			});
914
-			$manager->registerCapability(function () use ($c) {
914
+			$manager->registerCapability(function() use ($c) {
915 915
 				return $c->query(\OC\Security\Bruteforce\Capabilities::class);
916 916
 			});
917 917
 			return $manager;
918 918
 		});
919 919
 		$this->registerAlias('CapabilitiesManager', \OC\CapabilitiesManager::class);
920 920
 
921
-		$this->registerService(\OCP\Comments\ICommentsManager::class, function (Server $c) {
921
+		$this->registerService(\OCP\Comments\ICommentsManager::class, function(Server $c) {
922 922
 			$config = $c->getConfig();
923 923
 			$factoryClass = $config->getSystemValue('comments.managerFactory', CommentsManagerFactory::class);
924 924
 			/** @var \OCP\Comments\ICommentsManagerFactory $factory */
@@ -928,7 +928,7 @@  discard block
 block discarded – undo
928 928
 			$manager->registerDisplayNameResolver('user', function($id) use ($c) {
929 929
 				$manager = $c->getUserManager();
930 930
 				$user = $manager->get($id);
931
-				if(is_null($user)) {
931
+				if (is_null($user)) {
932 932
 					$l = $c->getL10N('core');
933 933
 					$displayName = $l->t('Unknown user');
934 934
 				} else {
@@ -941,7 +941,7 @@  discard block
 block discarded – undo
941 941
 		});
942 942
 		$this->registerAlias('CommentsManager', \OCP\Comments\ICommentsManager::class);
943 943
 
944
-		$this->registerService('ThemingDefaults', function (Server $c) {
944
+		$this->registerService('ThemingDefaults', function(Server $c) {
945 945
 			/*
946 946
 			 * Dark magic for autoloader.
947 947
 			 * If we do a class_exists it will try to load the class which will
@@ -969,7 +969,7 @@  discard block
 block discarded – undo
969 969
 			}
970 970
 			return new \OC_Defaults();
971 971
 		});
972
-		$this->registerService(SCSSCacher::class, function (Server $c) {
972
+		$this->registerService(SCSSCacher::class, function(Server $c) {
973 973
 			/** @var Factory $cacheFactory */
974 974
 			$cacheFactory = $c->query(Factory::class);
975 975
 			return new SCSSCacher(
@@ -984,7 +984,7 @@  discard block
 block discarded – undo
984 984
 				new TimeFactory()
985 985
 			);
986 986
 		});
987
-		$this->registerService(JSCombiner::class, function (Server $c) {
987
+		$this->registerService(JSCombiner::class, function(Server $c) {
988 988
 			/** @var Factory $cacheFactory */
989 989
 			$cacheFactory = $c->query(Factory::class);
990 990
 			return new JSCombiner(
@@ -995,13 +995,13 @@  discard block
 block discarded – undo
995 995
 				$c->getLogger()
996 996
 			);
997 997
 		});
998
-		$this->registerService(EventDispatcher::class, function () {
998
+		$this->registerService(EventDispatcher::class, function() {
999 999
 			return new EventDispatcher();
1000 1000
 		});
1001 1001
 		$this->registerAlias('EventDispatcher', EventDispatcher::class);
1002 1002
 		$this->registerAlias(EventDispatcherInterface::class, EventDispatcher::class);
1003 1003
 
1004
-		$this->registerService('CryptoWrapper', function (Server $c) {
1004
+		$this->registerService('CryptoWrapper', function(Server $c) {
1005 1005
 			// FIXME: Instantiiated here due to cyclic dependency
1006 1006
 			$request = new Request(
1007 1007
 				[
@@ -1026,7 +1026,7 @@  discard block
 block discarded – undo
1026 1026
 				$request
1027 1027
 			);
1028 1028
 		});
1029
-		$this->registerService('CsrfTokenManager', function (Server $c) {
1029
+		$this->registerService('CsrfTokenManager', function(Server $c) {
1030 1030
 			$tokenGenerator = new CsrfTokenGenerator($c->getSecureRandom());
1031 1031
 
1032 1032
 			return new CsrfTokenManager(
@@ -1034,22 +1034,22 @@  discard block
 block discarded – undo
1034 1034
 				$c->query(SessionStorage::class)
1035 1035
 			);
1036 1036
 		});
1037
-		$this->registerService(SessionStorage::class, function (Server $c) {
1037
+		$this->registerService(SessionStorage::class, function(Server $c) {
1038 1038
 			return new SessionStorage($c->getSession());
1039 1039
 		});
1040
-		$this->registerService(\OCP\Security\IContentSecurityPolicyManager::class, function (Server $c) {
1040
+		$this->registerService(\OCP\Security\IContentSecurityPolicyManager::class, function(Server $c) {
1041 1041
 			return new ContentSecurityPolicyManager();
1042 1042
 		});
1043 1043
 		$this->registerAlias('ContentSecurityPolicyManager', \OCP\Security\IContentSecurityPolicyManager::class);
1044 1044
 
1045
-		$this->registerService('ContentSecurityPolicyNonceManager', function (Server $c) {
1045
+		$this->registerService('ContentSecurityPolicyNonceManager', function(Server $c) {
1046 1046
 			return new ContentSecurityPolicyNonceManager(
1047 1047
 				$c->getCsrfTokenManager(),
1048 1048
 				$c->getRequest()
1049 1049
 			);
1050 1050
 		});
1051 1051
 
1052
-		$this->registerService(\OCP\Share\IManager::class, function (Server $c) {
1052
+		$this->registerService(\OCP\Share\IManager::class, function(Server $c) {
1053 1053
 			$config = $c->getConfig();
1054 1054
 			$factoryClass = $config->getSystemValue('sharing.managerFactory', ProviderFactory::class);
1055 1055
 			/** @var \OCP\Share\IProviderFactory $factory */
@@ -1096,7 +1096,7 @@  discard block
 block discarded – undo
1096 1096
 
1097 1097
 		$this->registerAlias(\OCP\Collaboration\Resources\IManager::class, \OC\Collaboration\Resources\Manager::class);
1098 1098
 
1099
-		$this->registerService('SettingsManager', function (Server $c) {
1099
+		$this->registerService('SettingsManager', function(Server $c) {
1100 1100
 			$manager = new \OC\Settings\Manager(
1101 1101
 				$c->getLogger(),
1102 1102
 				$c->getL10N('lib'),
@@ -1105,36 +1105,36 @@  discard block
 block discarded – undo
1105 1105
 			);
1106 1106
 			return $manager;
1107 1107
 		});
1108
-		$this->registerService(\OC\Files\AppData\Factory::class, function (Server $c) {
1108
+		$this->registerService(\OC\Files\AppData\Factory::class, function(Server $c) {
1109 1109
 			return new \OC\Files\AppData\Factory(
1110 1110
 				$c->getRootFolder(),
1111 1111
 				$c->getSystemConfig()
1112 1112
 			);
1113 1113
 		});
1114 1114
 
1115
-		$this->registerService('LockdownManager', function (Server $c) {
1116
-			return new LockdownManager(function () use ($c) {
1115
+		$this->registerService('LockdownManager', function(Server $c) {
1116
+			return new LockdownManager(function() use ($c) {
1117 1117
 				return $c->getSession();
1118 1118
 			});
1119 1119
 		});
1120 1120
 
1121
-		$this->registerService(\OCP\OCS\IDiscoveryService::class, function (Server $c) {
1121
+		$this->registerService(\OCP\OCS\IDiscoveryService::class, function(Server $c) {
1122 1122
 			return new DiscoveryService($c->getMemCacheFactory(), $c->getHTTPClientService());
1123 1123
 		});
1124 1124
 
1125
-		$this->registerService(ICloudIdManager::class, function (Server $c) {
1125
+		$this->registerService(ICloudIdManager::class, function(Server $c) {
1126 1126
 			return new CloudIdManager();
1127 1127
 		});
1128 1128
 
1129
-		$this->registerService(IConfig::class, function (Server $c) {
1129
+		$this->registerService(IConfig::class, function(Server $c) {
1130 1130
 			return new GlobalScale\Config($c->getConfig());
1131 1131
 		});
1132 1132
 
1133
-		$this->registerService(ICloudFederationProviderManager::class, function (Server $c) {
1133
+		$this->registerService(ICloudFederationProviderManager::class, function(Server $c) {
1134 1134
 			return new CloudFederationProviderManager($c->getAppManager(), $c->getHTTPClientService(), $c->getCloudIdManager(), $c->getLogger());
1135 1135
 		});
1136 1136
 
1137
-		$this->registerService(ICloudFederationFactory::class, function (Server $c) {
1137
+		$this->registerService(ICloudFederationFactory::class, function(Server $c) {
1138 1138
 			return new CloudFederationFactory();
1139 1139
 		});
1140 1140
 
@@ -1144,18 +1144,18 @@  discard block
 block discarded – undo
1144 1144
 		$this->registerAlias(\OCP\AppFramework\Utility\ITimeFactory::class, \OC\AppFramework\Utility\TimeFactory::class);
1145 1145
 		$this->registerAlias('TimeFactory', \OCP\AppFramework\Utility\ITimeFactory::class);
1146 1146
 
1147
-		$this->registerService(Defaults::class, function (Server $c) {
1147
+		$this->registerService(Defaults::class, function(Server $c) {
1148 1148
 			return new Defaults(
1149 1149
 				$c->getThemingDefaults()
1150 1150
 			);
1151 1151
 		});
1152 1152
 		$this->registerAlias('Defaults', \OCP\Defaults::class);
1153 1153
 
1154
-		$this->registerService(\OCP\ISession::class, function (SimpleContainer $c) {
1154
+		$this->registerService(\OCP\ISession::class, function(SimpleContainer $c) {
1155 1155
 			return $c->query(\OCP\IUserSession::class)->getSession();
1156 1156
 		});
1157 1157
 
1158
-		$this->registerService(IShareHelper::class, function (Server $c) {
1158
+		$this->registerService(IShareHelper::class, function(Server $c) {
1159 1159
 			return new ShareHelper(
1160 1160
 				$c->query(\OCP\Share\IManager::class)
1161 1161
 			);
@@ -1198,7 +1198,7 @@  discard block
 block discarded – undo
1198 1198
 		$this->registerAlias(IDashboardManager::class, DashboardManager::class);
1199 1199
 		$this->registerAlias(IFullTextSearchManager::class, FullTextSearchManager::class);
1200 1200
 
1201
-		$this->registerService(\OC\Security\IdentityProof\Manager::class, function (Server $c) {
1201
+		$this->registerService(\OC\Security\IdentityProof\Manager::class, function(Server $c) {
1202 1202
 			return new \OC\Security\IdentityProof\Manager(
1203 1203
 				$c->query(\OC\Files\AppData\Factory::class),
1204 1204
 				$c->getCrypto(),
@@ -1251,11 +1251,11 @@  discard block
 block discarded – undo
1251 1251
 				// no avatar to remove
1252 1252
 			} catch (\Exception $e) {
1253 1253
 				// Ignore exceptions
1254
-				$logger->info('Could not cleanup avatar of ' . $user->getUID());
1254
+				$logger->info('Could not cleanup avatar of '.$user->getUID());
1255 1255
 			}
1256 1256
 		});
1257 1257
 
1258
-		$dispatcher->addListener('OCP\IUser::changeUser', function (GenericEvent $e) {
1258
+		$dispatcher->addListener('OCP\IUser::changeUser', function(GenericEvent $e) {
1259 1259
 			$manager = $this->getAvatarManager();
1260 1260
 			/** @var IUser $user */
1261 1261
 			$user = $e->getSubject();
@@ -1406,7 +1406,7 @@  discard block
 block discarded – undo
1406 1406
 	 * @deprecated since 9.2.0 use IAppData
1407 1407
 	 */
1408 1408
 	public function getAppFolder() {
1409
-		$dir = '/' . \OC_App::getCurrentApp();
1409
+		$dir = '/'.\OC_App::getCurrentApp();
1410 1410
 		$root = $this->getRootFolder();
1411 1411
 		if (!$root->nodeExists($dir)) {
1412 1412
 			$folder = $root->newFolder($dir);
@@ -1981,7 +1981,7 @@  discard block
 block discarded – undo
1981 1981
 	/**
1982 1982
 	 * @return \OCP\Collaboration\AutoComplete\IManager
1983 1983
 	 */
1984
-	public function getAutoCompleteManager(){
1984
+	public function getAutoCompleteManager() {
1985 1985
 		return $this->query(IManager::class);
1986 1986
 	}
1987 1987
 
Please login to merge, or discard this patch.
lib/private/Collaboration/Resources/Manager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -150,7 +150,7 @@
 block discarded – undo
150 150
 		while ($row = $result->fetch()) {
151 151
 			$foundResults++;
152 152
 			$access = $row['access'] === null ? null : (bool) $row['access'];
153
-			$collection = new Collection($this, $this->connection, (int)$row['id'], (string)$row['name'], $user, $access);
153
+			$collection = new Collection($this, $this->connection, (int) $row['id'], (string) $row['name'], $user, $access);
154 154
 			if ($collection->canAccess($user)) {
155 155
 				$collections[] = $collection;
156 156
 			}
Please login to merge, or discard this patch.
lib/private/Collaboration/Resources/Listener.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -40,10 +40,10 @@  discard block
 block discarded – undo
40 40
 
41 41
 			$resourceManager->invalidateAccessCacheForUser($user);
42 42
 		};
43
-		$dispatcher->addListener(IGroup::class . '::postAddUser', $listener);
44
-		$dispatcher->addListener(IGroup::class . '::postRemoveUser', $listener);
43
+		$dispatcher->addListener(IGroup::class.'::postAddUser', $listener);
44
+		$dispatcher->addListener(IGroup::class.'::postRemoveUser', $listener);
45 45
 
46
-		$dispatcher->addListener(IUser::class . '::postDelete', function(GenericEvent $event) {
46
+		$dispatcher->addListener(IUser::class.'::postDelete', function(GenericEvent $event) {
47 47
 			/** @var IUser $user */
48 48
 			$user = $event->getSubject();
49 49
 			/** @var IManager $resourceManager */
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 			$resourceManager->invalidateAccessCacheForUser($user);
53 53
 		});
54 54
 
55
-		$dispatcher->addListener(IGroup::class . '::preDelete', function(GenericEvent $event) {
55
+		$dispatcher->addListener(IGroup::class.'::preDelete', function(GenericEvent $event) {
56 56
 			/** @var IGroup $group */
57 57
 			$group = $event->getSubject();
58 58
 			/** @var IManager $resourceManager */
Please login to merge, or discard this patch.
lib/private/User/Manager.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
 		$this->config = $config;
79 79
 		$this->dispatcher = $dispatcher;
80 80
 		$cachedUsers = &$this->cachedUsers;
81
-		$this->listen('\OC\User', 'postDelete', function ($user) use (&$cachedUsers) {
81
+		$this->listen('\OC\User', 'postDelete', function($user) use (&$cachedUsers) {
82 82
 			/** @var \OC\User\User $user */
83 83
 			unset($cachedUsers[$user->getUID()]);
84 84
 		});
@@ -184,7 +184,7 @@  discard block
 block discarded – undo
184 184
 		$result = $this->checkPasswordNoLogging($loginName, $password);
185 185
 
186 186
 		if ($result === false) {
187
-			\OC::$server->getLogger()->warning('Login failed: \''. $loginName .'\' (Remote IP: \''. \OC::$server->getRequest()->getRemoteAddress(). '\')', ['app' => 'core']);
187
+			\OC::$server->getLogger()->warning('Login failed: \''.$loginName.'\' (Remote IP: \''.\OC::$server->getRequest()->getRemoteAddress().'\')', ['app' => 'core']);
188 188
 		}
189 189
 
190 190
 		return $result;
@@ -233,7 +233,7 @@  discard block
 block discarded – undo
233 233
 			}
234 234
 		}
235 235
 
236
-		uasort($users, function ($a, $b) {
236
+		uasort($users, function($a, $b) {
237 237
 			/**
238 238
 			 * @var \OC\User\User $a
239 239
 			 * @var \OC\User\User $b
@@ -262,7 +262,7 @@  discard block
 block discarded – undo
262 262
 			}
263 263
 		}
264 264
 
265
-		usort($users, function ($a, $b) {
265
+		usort($users, function($a, $b) {
266 266
 			/**
267 267
 			 * @var \OC\User\User $a
268 268
 			 * @var \OC\User\User $b
@@ -341,7 +341,7 @@  discard block
 block discarded – undo
341 341
 
342 342
 		$this->emit('\OC\User', 'preCreateUser', [$uid, $password]);
343 343
 		$state = $backend->createUser($uid, $password);
344
-		if($state === false) {
344
+		if ($state === false) {
345 345
 			throw new \InvalidArgumentException($l->t('Could not create user'));
346 346
 		}
347 347
 		$user = $this->getUserObject($uid, $backend);
@@ -367,13 +367,13 @@  discard block
 block discarded – undo
367 367
 		foreach ($this->backends as $backend) {
368 368
 			if ($backend->implementsActions(Backend::COUNT_USERS)) {
369 369
 				$backendUsers = $backend->countUsers();
370
-				if($backendUsers !== false) {
371
-					if($backend instanceof IUserBackend) {
370
+				if ($backendUsers !== false) {
371
+					if ($backend instanceof IUserBackend) {
372 372
 						$name = $backend->getBackendName();
373 373
 					} else {
374 374
 						$name = get_class($backend);
375 375
 					}
376
-					if(isset($userCountStatistics[$name])) {
376
+					if (isset($userCountStatistics[$name])) {
377 377
 						$userCountStatistics[$name] += $backendUsers;
378 378
 					} else {
379 379
 						$userCountStatistics[$name] = $backendUsers;
@@ -393,7 +393,7 @@  discard block
 block discarded – undo
393 393
 	 */
394 394
 	public function countUsersOfGroups(array $groups) {
395 395
 		$users = [];
396
-		foreach($groups as $group) {
396
+		foreach ($groups as $group) {
397 397
 			$usersIds = array_map(function($user) {
398 398
 				return $user->getUID();
399 399
 			}, $group->getUsers());
@@ -457,7 +457,7 @@  discard block
 block discarded – undo
457 457
 		$result->closeCursor();
458 458
 		
459 459
 		if ($count !== false) {
460
-			$count = (int)$count;
460
+			$count = (int) $count;
461 461
 		} else {
462 462
 			$count = 0;
463 463
 		}
@@ -474,7 +474,7 @@  discard block
 block discarded – undo
474 474
 	 */
475 475
 	public function countDisabledUsersOfGroups(array $groups): int {
476 476
 		$queryBuilder = \OC::$server->getDatabaseConnection()->getQueryBuilder();
477
-		$queryBuilder->select($queryBuilder->createFunction('COUNT(DISTINCT ' . $queryBuilder->getColumnName('uid') . ')'))
477
+		$queryBuilder->select($queryBuilder->createFunction('COUNT(DISTINCT '.$queryBuilder->getColumnName('uid').')'))
478 478
 			->from('preferences', 'p')
479 479
 			->innerJoin('p', 'group_user', 'g', $queryBuilder->expr()->eq('p.userid', 'g.uid'))
480 480
 			->where($queryBuilder->expr()->eq('appid', $queryBuilder->createNamedParameter('core')))
@@ -487,7 +487,7 @@  discard block
 block discarded – undo
487 487
 		$result->closeCursor();
488 488
 		
489 489
 		if ($count !== false) {
490
-			$count = (int)$count;
490
+			$count = (int) $count;
491 491
 		} else {
492 492
 			$count = 0;
493 493
 		}
@@ -511,7 +511,7 @@  discard block
 block discarded – undo
511 511
 
512 512
 		$query = $queryBuilder->execute();
513 513
 
514
-		$result = (int)$query->fetchColumn();
514
+		$result = (int) $query->fetchColumn();
515 515
 		$query->closeCursor();
516 516
 
517 517
 		return $result;
Please login to merge, or discard this patch.
lib/private/User/User.php 1 patch
Spacing   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
 		$this->backend = $backend;
84 84
 		$this->dispatcher = $dispatcher;
85 85
 		$this->emitter = $emitter;
86
-		if(is_null($config)) {
86
+		if (is_null($config)) {
87 87
 			$config = \OC::$server->getConfig();
88 88
 		}
89 89
 		$this->config = $config;
@@ -159,12 +159,12 @@  discard block
 block discarded – undo
159 159
 	 */
160 160
 	public function setEMailAddress($mailAddress) {
161 161
 		$oldMailAddress = $this->getEMailAddress();
162
-		if($mailAddress === '') {
162
+		if ($mailAddress === '') {
163 163
 			$this->config->deleteUserValue($this->uid, 'settings', 'email');
164 164
 		} else {
165 165
 			$this->config->setUserValue($this->uid, 'settings', 'email', $mailAddress);
166 166
 		}
167
-		if($oldMailAddress !== $mailAddress) {
167
+		if ($oldMailAddress !== $mailAddress) {
168 168
 			$this->triggerChange('eMailAddress', $mailAddress, $oldMailAddress);
169 169
 		}
170 170
 	}
@@ -197,7 +197,7 @@  discard block
 block discarded – undo
197 197
 	 * @return bool
198 198
 	 */
199 199
 	public function delete() {
200
-		$this->dispatcher->dispatch(IUser::class . '::preDelete', new GenericEvent($this));
200
+		$this->dispatcher->dispatch(IUser::class.'::preDelete', new GenericEvent($this));
201 201
 		if ($this->emitter) {
202 202
 			$this->emitter->emit('\OC\User', 'preDelete', array($this));
203 203
 		}
@@ -229,7 +229,7 @@  discard block
 block discarded – undo
229 229
 			}
230 230
 
231 231
 			// Delete the users entry in the storage table
232
-			Storage::remove('home::' . $this->uid);
232
+			Storage::remove('home::'.$this->uid);
233 233
 
234 234
 			\OC::$server->getCommentsManager()->deleteReferencesOfActor('users', $this->uid);
235 235
 			\OC::$server->getCommentsManager()->deleteReadMarksFromUser($this);
@@ -242,7 +242,7 @@  discard block
 block discarded – undo
242 242
 			$accountManager = \OC::$server->query(AccountManager::class);
243 243
 			$accountManager->deleteUser($this);
244 244
 
245
-			$this->dispatcher->dispatch(IUser::class . '::postDelete', new GenericEvent($this));
245
+			$this->dispatcher->dispatch(IUser::class.'::postDelete', new GenericEvent($this));
246 246
 			if ($this->emitter) {
247 247
 				$this->emitter->emit('\OC\User', 'postDelete', array($this));
248 248
 			}
@@ -258,7 +258,7 @@  discard block
 block discarded – undo
258 258
 	 * @return bool
259 259
 	 */
260 260
 	public function setPassword($password, $recoveryPassword = null) {
261
-		$this->dispatcher->dispatch(IUser::class . '::preSetPassword', new GenericEvent($this, [
261
+		$this->dispatcher->dispatch(IUser::class.'::preSetPassword', new GenericEvent($this, [
262 262
 			'password' => $password,
263 263
 			'recoveryPassword' => $recoveryPassword,
264 264
 		]));
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
 		}
268 268
 		if ($this->backend->implementsActions(Backend::SET_PASSWORD)) {
269 269
 			$result = $this->backend->setPassword($this->uid, $password);
270
-			$this->dispatcher->dispatch(IUser::class . '::postSetPassword', new GenericEvent($this, [
270
+			$this->dispatcher->dispatch(IUser::class.'::postSetPassword', new GenericEvent($this, [
271 271
 				'password' => $password,
272 272
 				'recoveryPassword' => $recoveryPassword,
273 273
 			]));
@@ -290,9 +290,9 @@  discard block
 block discarded – undo
290 290
 			if ($this->backend->implementsActions(Backend::GET_HOME) and $home = $this->backend->getHome($this->uid)) {
291 291
 				$this->home = $home;
292 292
 			} elseif ($this->config) {
293
-				$this->home = $this->config->getSystemValue('datadirectory', \OC::$SERVERROOT . '/data') . '/' . $this->uid;
293
+				$this->home = $this->config->getSystemValue('datadirectory', \OC::$SERVERROOT.'/data').'/'.$this->uid;
294 294
 			} else {
295
-				$this->home = \OC::$SERVERROOT . '/data/' . $this->uid;
295
+				$this->home = \OC::$SERVERROOT.'/data/'.$this->uid;
296 296
 			}
297 297
 		}
298 298
 		return $this->home;
@@ -304,7 +304,7 @@  discard block
 block discarded – undo
304 304
 	 * @return string
305 305
 	 */
306 306
 	public function getBackendClassName() {
307
-		if($this->backend instanceof IUserBackend) {
307
+		if ($this->backend instanceof IUserBackend) {
308 308
 			return $this->backend->getBackendName();
309 309
 		}
310 310
 		return get_class($this->backend);
@@ -388,7 +388,7 @@  discard block
 block discarded – undo
388 388
 	 */
389 389
 	public function getQuota() {
390 390
 		$quota = $this->config->getUserValue($this->uid, 'files', 'quota', 'default');
391
-		if($quota === 'default') {
391
+		if ($quota === 'default') {
392 392
 			$quota = $this->config->getAppValue('files', 'default_quota', 'none');
393 393
 		}
394 394
 		return $quota;
@@ -403,12 +403,12 @@  discard block
 block discarded – undo
403 403
 	 */
404 404
 	public function setQuota($quota) {
405 405
 		$oldQuota = $this->config->getUserValue($this->uid, 'files', 'quota', '');
406
-		if($quota !== 'none' and $quota !== 'default') {
406
+		if ($quota !== 'none' and $quota !== 'default') {
407 407
 			$quota = OC_Helper::computerFileSize($quota);
408 408
 			$quota = OC_Helper::humanFileSize($quota);
409 409
 		}
410 410
 		$this->config->setUserValue($this->uid, 'files', 'quota', $quota);
411
-		if($quota !== $oldQuota) {
411
+		if ($quota !== $oldQuota) {
412 412
 			$this->triggerChange('quota', $quota);
413 413
 		}
414 414
 	}
@@ -444,7 +444,7 @@  discard block
 block discarded – undo
444 444
 	public function getCloudId() {
445 445
 		$uid = $this->getUID();
446 446
 		$server = $this->urlGenerator->getAbsoluteURL('/');
447
-		$server =  rtrim( $this->removeProtocolFromUrl($server), '/');
447
+		$server = rtrim($this->removeProtocolFromUrl($server), '/');
448 448
 		return \OC::$server->getCloudIdManager()->getCloudId($uid, $server)->getId();
449 449
 	}
450 450
 
@@ -463,7 +463,7 @@  discard block
 block discarded – undo
463 463
 	}
464 464
 
465 465
 	public function triggerChange($feature, $value = null, $oldValue = null) {
466
-		$this->dispatcher->dispatch(IUser::class . '::changeUser', new GenericEvent($this, [
466
+		$this->dispatcher->dispatch(IUser::class.'::changeUser', new GenericEvent($this, [
467 467
 			'feature' => $feature,
468 468
 			'value' => $value,
469 469
 			'oldValue' => $oldValue,
Please login to merge, or discard this patch.
lib/private/Group/Manager.php 1 patch
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -95,20 +95,20 @@  discard block
 block discarded – undo
95 95
 
96 96
 		$cachedGroups = & $this->cachedGroups;
97 97
 		$cachedUserGroups = & $this->cachedUserGroups;
98
-		$this->listen('\OC\Group', 'postDelete', function ($group) use (&$cachedGroups, &$cachedUserGroups) {
98
+		$this->listen('\OC\Group', 'postDelete', function($group) use (&$cachedGroups, &$cachedUserGroups) {
99 99
 			/**
100 100
 			 * @var \OC\Group\Group $group
101 101
 			 */
102 102
 			unset($cachedGroups[$group->getGID()]);
103 103
 			$cachedUserGroups = [];
104 104
 		});
105
-		$this->listen('\OC\Group', 'postAddUser', function ($group) use (&$cachedUserGroups) {
105
+		$this->listen('\OC\Group', 'postAddUser', function($group) use (&$cachedUserGroups) {
106 106
 			/**
107 107
 			 * @var \OC\Group\Group $group
108 108
 			 */
109 109
 			$cachedUserGroups = [];
110 110
 		});
111
-		$this->listen('\OC\Group', 'postRemoveUser', function ($group) use (&$cachedUserGroups) {
111
+		$this->listen('\OC\Group', 'postRemoveUser', function($group) use (&$cachedUserGroups) {
112 112
 			/**
113 113
 			 * @var \OC\Group\Group $group
114 114
 			 */
@@ -246,7 +246,7 @@  discard block
 block discarded – undo
246 246
 				if ($aGroup instanceof IGroup) {
247 247
 					$groups[$groupId] = $aGroup;
248 248
 				} else {
249
-					$this->logger->debug('Group "' . $groupId . '" was returned by search but not found through direct access', ['app' => 'core']);
249
+					$this->logger->debug('Group "'.$groupId.'" was returned by search but not found through direct access', ['app' => 'core']);
250 250
 				}
251 251
 			}
252 252
 			if (!is_null($limit) and $limit <= 0) {
@@ -260,7 +260,7 @@  discard block
 block discarded – undo
260 260
 	 * @param IUser|null $user
261 261
 	 * @return \OC\Group\Group[]
262 262
 	 */
263
-	public function getUserGroups(IUser $user= null) {
263
+	public function getUserGroups(IUser $user = null) {
264 264
 		if (!$user instanceof IUser) {
265 265
 			return [];
266 266
 		}
@@ -284,7 +284,7 @@  discard block
 block discarded – undo
284 284
 					if ($aGroup instanceof IGroup) {
285 285
 						$groups[$groupId] = $aGroup;
286 286
 					} else {
287
-						$this->logger->debug('User "' . $uid . '" belongs to deleted group: "' . $groupId . '"', ['app' => 'core']);
287
+						$this->logger->debug('User "'.$uid.'" belongs to deleted group: "'.$groupId.'"', ['app' => 'core']);
288 288
 					}
289 289
 				}
290 290
 			}
@@ -349,32 +349,32 @@  discard block
 block discarded – undo
349 349
 	 */
350 350
 	public function displayNamesInGroup($gid, $search = '', $limit = -1, $offset = 0) {
351 351
 		$group = $this->get($gid);
352
-		if(is_null($group)) {
352
+		if (is_null($group)) {
353 353
 			return [];
354 354
 		}
355 355
 
356 356
 		$search = trim($search);
357 357
 		$groupUsers = [];
358 358
 
359
-		if(!empty($search)) {
359
+		if (!empty($search)) {
360 360
 			// only user backends have the capability to do a complex search for users
361 361
 			$searchOffset = 0;
362 362
 			$searchLimit = $limit * 100;
363
-			if($limit === -1) {
363
+			if ($limit === -1) {
364 364
 				$searchLimit = 500;
365 365
 			}
366 366
 
367 367
 			do {
368 368
 				$filteredUsers = $this->userManager->searchDisplayName($search, $searchLimit, $searchOffset);
369
-				foreach($filteredUsers as $filteredUser) {
370
-					if($group->inGroup($filteredUser)) {
371
-						$groupUsers[]= $filteredUser;
369
+				foreach ($filteredUsers as $filteredUser) {
370
+					if ($group->inGroup($filteredUser)) {
371
+						$groupUsers[] = $filteredUser;
372 372
 					}
373 373
 				}
374 374
 				$searchOffset += $searchLimit;
375
-			} while(count($groupUsers) < $searchLimit+$offset && count($filteredUsers) >= $searchLimit);
375
+			} while (count($groupUsers) < $searchLimit + $offset && count($filteredUsers) >= $searchLimit);
376 376
 
377
-			if($limit === -1) {
377
+			if ($limit === -1) {
378 378
 				$groupUsers = array_slice($groupUsers, $offset);
379 379
 			} else {
380 380
 				$groupUsers = array_slice($groupUsers, $offset, $limit);
@@ -384,7 +384,7 @@  discard block
 block discarded – undo
384 384
 		}
385 385
 
386 386
 		$matchingUsers = [];
387
-		foreach($groupUsers as $groupUser) {
387
+		foreach ($groupUsers as $groupUser) {
388 388
 			$matchingUsers[$groupUser->getUID()] = $groupUser->getDisplayName();
389 389
 		}
390 390
 		return $matchingUsers;
Please login to merge, or discard this patch.
lib/private/Group/Group.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
 			return;
147 147
 		}
148 148
 
149
-		$this->dispatcher->dispatch(IGroup::class . '::preAddUser', new GenericEvent($this, [
149
+		$this->dispatcher->dispatch(IGroup::class.'::preAddUser', new GenericEvent($this, [
150 150
 			'user' => $user,
151 151
 		]));
152 152
 
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
 					$this->users[$user->getUID()] = $user;
161 161
 				}
162 162
 
163
-				$this->dispatcher->dispatch(IGroup::class . '::postAddUser', new GenericEvent($this, [
163
+				$this->dispatcher->dispatch(IGroup::class.'::postAddUser', new GenericEvent($this, [
164 164
 					'user' => $user,
165 165
 				]));
166 166
 
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
 	 */
180 180
 	public function removeUser($user) {
181 181
 		$result = false;
182
-		$this->dispatcher->dispatch(IGroup::class . '::preRemoveUser', new GenericEvent($this, [
182
+		$this->dispatcher->dispatch(IGroup::class.'::preRemoveUser', new GenericEvent($this, [
183 183
 			'user' => $user,
184 184
 		]));
185 185
 		if ($this->emitter) {
@@ -192,7 +192,7 @@  discard block
 block discarded – undo
192 192
 			}
193 193
 		}
194 194
 		if ($result) {
195
-			$this->dispatcher->dispatch(IGroup::class . '::postRemoveUser', new GenericEvent($this, [
195
+			$this->dispatcher->dispatch(IGroup::class.'::postRemoveUser', new GenericEvent($this, [
196 196
 				'user' => $user,
197 197
 			]));
198 198
 			if ($this->emitter) {
@@ -238,8 +238,8 @@  discard block
 block discarded – undo
238 238
 	public function count($search = '') {
239 239
 		$users = false;
240 240
 		foreach ($this->backends as $backend) {
241
-			if($backend->implementsActions(\OC\Group\Backend::COUNT_USERS)) {
242
-				if($users === false) {
241
+			if ($backend->implementsActions(\OC\Group\Backend::COUNT_USERS)) {
242
+				if ($users === false) {
243 243
 					//we could directly add to a bool variable, but this would
244 244
 					//be ugly
245 245
 					$users = 0;
@@ -258,8 +258,8 @@  discard block
 block discarded – undo
258 258
 	public function countDisabled() {
259 259
 		$users = false;
260 260
 		foreach ($this->backends as $backend) {
261
-			if($backend instanceOf ICountDisabledInGroup) {
262
-				if($users === false) {
261
+			if ($backend instanceOf ICountDisabledInGroup) {
262
+				if ($users === false) {
263 263
 					//we could directly add to a bool variable, but this would
264 264
 					//be ugly
265 265
 					$users = 0;
@@ -302,7 +302,7 @@  discard block
 block discarded – undo
302 302
 		}
303 303
 
304 304
 		$result = false;
305
-		$this->dispatcher->dispatch(IGroup::class . '::preDelete', new GenericEvent($this));
305
+		$this->dispatcher->dispatch(IGroup::class.'::preDelete', new GenericEvent($this));
306 306
 		if ($this->emitter) {
307 307
 			$this->emitter->emit('\OC\Group', 'preDelete', array($this));
308 308
 		}
@@ -313,7 +313,7 @@  discard block
 block discarded – undo
313 313
 			}
314 314
 		}
315 315
 		if ($result) {
316
-			$this->dispatcher->dispatch(IGroup::class . '::postDelete', new GenericEvent($this));
316
+			$this->dispatcher->dispatch(IGroup::class.'::postDelete', new GenericEvent($this));
317 317
 			if ($this->emitter) {
318 318
 				$this->emitter->emit('\OC\Group', 'postDelete', array($this));
319 319
 			}
Please login to merge, or discard this patch.