Passed
Push — master ( 613f0f...8f650f )
by Roeland
11:57 queued 12s
created
core/routes.php 1 patch
Indentation   +74 added lines, -74 removed lines patch added patch discarded remove patch
@@ -37,83 +37,83 @@  discard block
 block discarded – undo
37 37
 /** @var Application $application */
38 38
 $application = \OC::$server->query(Application::class);
39 39
 $application->registerRoutes($this, [
40
-	'routes' => [
41
-		['name' => 'lost#email', 'url' => '/lostpassword/email', 'verb' => 'POST'],
42
-		['name' => 'lost#resetform', 'url' => '/lostpassword/reset/form/{token}/{userId}', 'verb' => 'GET'],
43
-		['name' => 'lost#setPassword', 'url' => '/lostpassword/set/{token}/{userId}', 'verb' => 'POST'],
44
-		['name' => 'user#getDisplayNames', 'url' => '/displaynames', 'verb' => 'POST'],
45
-		['name' => 'avatar#getAvatar', 'url' => '/avatar/{userId}/{size}', 'verb' => 'GET'],
46
-		['name' => 'avatar#deleteAvatar', 'url' => '/avatar/', 'verb' => 'DELETE'],
47
-		['name' => 'avatar#postCroppedAvatar', 'url' => '/avatar/cropped', 'verb' => 'POST'],
48
-		['name' => 'avatar#getTmpAvatar', 'url' => '/avatar/tmp', 'verb' => 'GET'],
49
-		['name' => 'avatar#postAvatar', 'url' => '/avatar/', 'verb' => 'POST'],
50
-		['name' => 'GuestAvatar#getAvatar', 'url' => '/avatar/guest/{guestName}/{size}', 'verb' => 'GET'],
51
-		['name' => 'CSRFToken#index', 'url' => '/csrftoken', 'verb' => 'GET'],
52
-		['name' => 'login#tryLogin', 'url' => '/login', 'verb' => 'POST'],
53
-		['name' => 'login#confirmPassword', 'url' => '/login/confirm', 'verb' => 'POST'],
54
-		['name' => 'login#showLoginForm', 'url' => '/login', 'verb' => 'GET'],
55
-		['name' => 'login#logout', 'url' => '/logout', 'verb' => 'GET'],
56
-		// Original login flow used by all clients
57
-		['name' => 'ClientFlowLogin#showAuthPickerPage', 'url' => '/login/flow', 'verb' => 'GET'],
58
-		['name' => 'ClientFlowLogin#generateAppPassword', 'url' => '/login/flow', 'verb' => 'POST'],
59
-		['name' => 'ClientFlowLogin#grantPage', 'url' => '/login/flow/grant', 'verb' => 'GET'],
60
-		['name' => 'ClientFlowLogin#apptokenRedirect', 'url' => '/login/flow/apptoken', 'verb' => 'POST'],
61
-		// NG login flow used by desktop client in case of Kerberos/fancy 2fa (smart cards for example)
62
-		['name' => 'ClientFlowLoginV2#poll', 'url' => '/login/v2/poll', 'verb' => 'POST'],
63
-		['name' => 'ClientFlowLoginV2#showAuthPickerPage', 'url' => '/login/v2/flow', 'verb' => 'GET'],
64
-		['name' => 'ClientFlowLoginV2#landing', 'url' => '/login/v2/flow/{token}', 'verb' => 'GET'],
65
-		['name' => 'ClientFlowLoginV2#grantPage', 'url' => '/login/v2/grant', 'verb' => 'GET'],
66
-		['name' => 'ClientFlowLoginV2#generateAppPassword', 'url' => '/login/v2/grant', 'verb' => 'POST'],
67
-		['name' => 'ClientFlowLoginV2#init', 'url' => '/login/v2', 'verb' => 'POST'],
68
-		['name' => 'TwoFactorChallenge#selectChallenge', 'url' => '/login/selectchallenge', 'verb' => 'GET'],
69
-		['name' => 'TwoFactorChallenge#showChallenge', 'url' => '/login/challenge/{challengeProviderId}', 'verb' => 'GET'],
70
-		['name' => 'TwoFactorChallenge#solveChallenge', 'url' => '/login/challenge/{challengeProviderId}', 'verb' => 'POST'],
71
-		['name' => 'TwoFactorChallenge#setupProviders', 'url' => 'login/setupchallenge', 'verb' => 'GET'],
72
-		['name' => 'TwoFactorChallenge#setupProvider', 'url' => 'login/setupchallenge/{providerId}', 'verb' => 'GET'],
73
-		['name' => 'TwoFactorChallenge#confirmProviderSetup', 'url' => 'login/setupchallenge/{providerId}', 'verb' => 'POST'],
74
-		['name' => 'OCJS#getConfig', 'url' => '/core/js/oc.js', 'verb' => 'GET'],
75
-		['name' => 'Preview#getPreviewByFileId', 'url' => '/core/preview', 'verb' => 'GET'],
76
-		['name' => 'Preview#getPreview', 'url' => '/core/preview.png', 'verb' => 'GET'],
77
-		['name' => 'RecommendedApps#index', 'url' => '/core/apps/recommended', 'verb' => 'GET'],
78
-		['name' => 'Svg#getSvgFromCore', 'url' => '/svg/core/{folder}/{fileName}', 'verb' => 'GET'],
79
-		['name' => 'Svg#getSvgFromApp', 'url' => '/svg/{app}/{fileName}', 'verb' => 'GET'],
80
-		['name' => 'Css#getCss', 'url' => '/css/{appName}/{fileName}', 'verb' => 'GET'],
81
-		['name' => 'Js#getJs', 'url' => '/js/{appName}/{fileName}', 'verb' => 'GET'],
82
-		['name' => 'contactsMenu#index', 'url' => '/contactsmenu/contacts', 'verb' => 'POST'],
83
-		['name' => 'contactsMenu#findOne', 'url' => '/contactsmenu/findOne', 'verb' => 'POST'],
84
-		['name' => 'WalledGarden#get', 'url' => '/204', 'verb' => 'GET'],
85
-		['name' => 'Search#search', 'url' => '/core/search', 'verb' => 'GET'],
86
-		['name' => 'Wipe#checkWipe', 'url' => '/core/wipe/check', 'verb' => 'POST'],
87
-		['name' => 'Wipe#wipeDone', 'url' => '/core/wipe/success', 'verb' => 'POST'],
40
+    'routes' => [
41
+        ['name' => 'lost#email', 'url' => '/lostpassword/email', 'verb' => 'POST'],
42
+        ['name' => 'lost#resetform', 'url' => '/lostpassword/reset/form/{token}/{userId}', 'verb' => 'GET'],
43
+        ['name' => 'lost#setPassword', 'url' => '/lostpassword/set/{token}/{userId}', 'verb' => 'POST'],
44
+        ['name' => 'user#getDisplayNames', 'url' => '/displaynames', 'verb' => 'POST'],
45
+        ['name' => 'avatar#getAvatar', 'url' => '/avatar/{userId}/{size}', 'verb' => 'GET'],
46
+        ['name' => 'avatar#deleteAvatar', 'url' => '/avatar/', 'verb' => 'DELETE'],
47
+        ['name' => 'avatar#postCroppedAvatar', 'url' => '/avatar/cropped', 'verb' => 'POST'],
48
+        ['name' => 'avatar#getTmpAvatar', 'url' => '/avatar/tmp', 'verb' => 'GET'],
49
+        ['name' => 'avatar#postAvatar', 'url' => '/avatar/', 'verb' => 'POST'],
50
+        ['name' => 'GuestAvatar#getAvatar', 'url' => '/avatar/guest/{guestName}/{size}', 'verb' => 'GET'],
51
+        ['name' => 'CSRFToken#index', 'url' => '/csrftoken', 'verb' => 'GET'],
52
+        ['name' => 'login#tryLogin', 'url' => '/login', 'verb' => 'POST'],
53
+        ['name' => 'login#confirmPassword', 'url' => '/login/confirm', 'verb' => 'POST'],
54
+        ['name' => 'login#showLoginForm', 'url' => '/login', 'verb' => 'GET'],
55
+        ['name' => 'login#logout', 'url' => '/logout', 'verb' => 'GET'],
56
+        // Original login flow used by all clients
57
+        ['name' => 'ClientFlowLogin#showAuthPickerPage', 'url' => '/login/flow', 'verb' => 'GET'],
58
+        ['name' => 'ClientFlowLogin#generateAppPassword', 'url' => '/login/flow', 'verb' => 'POST'],
59
+        ['name' => 'ClientFlowLogin#grantPage', 'url' => '/login/flow/grant', 'verb' => 'GET'],
60
+        ['name' => 'ClientFlowLogin#apptokenRedirect', 'url' => '/login/flow/apptoken', 'verb' => 'POST'],
61
+        // NG login flow used by desktop client in case of Kerberos/fancy 2fa (smart cards for example)
62
+        ['name' => 'ClientFlowLoginV2#poll', 'url' => '/login/v2/poll', 'verb' => 'POST'],
63
+        ['name' => 'ClientFlowLoginV2#showAuthPickerPage', 'url' => '/login/v2/flow', 'verb' => 'GET'],
64
+        ['name' => 'ClientFlowLoginV2#landing', 'url' => '/login/v2/flow/{token}', 'verb' => 'GET'],
65
+        ['name' => 'ClientFlowLoginV2#grantPage', 'url' => '/login/v2/grant', 'verb' => 'GET'],
66
+        ['name' => 'ClientFlowLoginV2#generateAppPassword', 'url' => '/login/v2/grant', 'verb' => 'POST'],
67
+        ['name' => 'ClientFlowLoginV2#init', 'url' => '/login/v2', 'verb' => 'POST'],
68
+        ['name' => 'TwoFactorChallenge#selectChallenge', 'url' => '/login/selectchallenge', 'verb' => 'GET'],
69
+        ['name' => 'TwoFactorChallenge#showChallenge', 'url' => '/login/challenge/{challengeProviderId}', 'verb' => 'GET'],
70
+        ['name' => 'TwoFactorChallenge#solveChallenge', 'url' => '/login/challenge/{challengeProviderId}', 'verb' => 'POST'],
71
+        ['name' => 'TwoFactorChallenge#setupProviders', 'url' => 'login/setupchallenge', 'verb' => 'GET'],
72
+        ['name' => 'TwoFactorChallenge#setupProvider', 'url' => 'login/setupchallenge/{providerId}', 'verb' => 'GET'],
73
+        ['name' => 'TwoFactorChallenge#confirmProviderSetup', 'url' => 'login/setupchallenge/{providerId}', 'verb' => 'POST'],
74
+        ['name' => 'OCJS#getConfig', 'url' => '/core/js/oc.js', 'verb' => 'GET'],
75
+        ['name' => 'Preview#getPreviewByFileId', 'url' => '/core/preview', 'verb' => 'GET'],
76
+        ['name' => 'Preview#getPreview', 'url' => '/core/preview.png', 'verb' => 'GET'],
77
+        ['name' => 'RecommendedApps#index', 'url' => '/core/apps/recommended', 'verb' => 'GET'],
78
+        ['name' => 'Svg#getSvgFromCore', 'url' => '/svg/core/{folder}/{fileName}', 'verb' => 'GET'],
79
+        ['name' => 'Svg#getSvgFromApp', 'url' => '/svg/{app}/{fileName}', 'verb' => 'GET'],
80
+        ['name' => 'Css#getCss', 'url' => '/css/{appName}/{fileName}', 'verb' => 'GET'],
81
+        ['name' => 'Js#getJs', 'url' => '/js/{appName}/{fileName}', 'verb' => 'GET'],
82
+        ['name' => 'contactsMenu#index', 'url' => '/contactsmenu/contacts', 'verb' => 'POST'],
83
+        ['name' => 'contactsMenu#findOne', 'url' => '/contactsmenu/findOne', 'verb' => 'POST'],
84
+        ['name' => 'WalledGarden#get', 'url' => '/204', 'verb' => 'GET'],
85
+        ['name' => 'Search#search', 'url' => '/core/search', 'verb' => 'GET'],
86
+        ['name' => 'Wipe#checkWipe', 'url' => '/core/wipe/check', 'verb' => 'POST'],
87
+        ['name' => 'Wipe#wipeDone', 'url' => '/core/wipe/success', 'verb' => 'POST'],
88 88
 
89
-		// Logins for passwordless auth
90
-		['name' => 'WebAuthn#startAuthentication', 'url' => 'login/webauthn/start', 'verb' => 'POST'],
91
-		['name' => 'WebAuthn#finishAuthentication', 'url' => 'login/webauthn/finish', 'verb' => 'POST'],
92
-	],
93
-	'ocs' => [
94
-		['root' => '/cloud', 'name' => 'OCS#getCapabilities', 'url' => '/capabilities', 'verb' => 'GET'],
95
-		['root' => '', 'name' => 'OCS#getConfig', 'url' => '/config', 'verb' => 'GET'],
96
-		['root' => '/person', 'name' => 'OCS#personCheck', 'url' => '/check', 'verb' => 'POST'],
97
-		['root' => '/identityproof', 'name' => 'OCS#getIdentityProof', 'url' => '/key/{cloudId}', 'verb' => 'GET'],
98
-		['root' => '/core', 'name' => 'Navigation#getAppsNavigation', 'url' => '/navigation/apps', 'verb' => 'GET'],
99
-		['root' => '/core', 'name' => 'Navigation#getSettingsNavigation', 'url' => '/navigation/settings', 'verb' => 'GET'],
100
-		['root' => '/core', 'name' => 'AutoComplete#get', 'url' => '/autocomplete/get', 'verb' => 'GET'],
101
-		['root' => '/core', 'name' => 'WhatsNew#get', 'url' => '/whatsnew', 'verb' => 'GET'],
102
-		['root' => '/core', 'name' => 'WhatsNew#dismiss', 'url' => '/whatsnew', 'verb' => 'POST'],
103
-		['root' => '/core', 'name' => 'AppPassword#getAppPassword', 'url' => '/getapppassword', 'verb' => 'GET'],
104
-		['root' => '/core', 'name' => 'AppPassword#rotateAppPassword', 'url' => '/apppassword/rotate', 'verb' => 'POST'],
105
-		['root' => '/core', 'name' => 'AppPassword#deleteAppPassword', 'url' => '/apppassword', 'verb' => 'DELETE'],
89
+        // Logins for passwordless auth
90
+        ['name' => 'WebAuthn#startAuthentication', 'url' => 'login/webauthn/start', 'verb' => 'POST'],
91
+        ['name' => 'WebAuthn#finishAuthentication', 'url' => 'login/webauthn/finish', 'verb' => 'POST'],
92
+    ],
93
+    'ocs' => [
94
+        ['root' => '/cloud', 'name' => 'OCS#getCapabilities', 'url' => '/capabilities', 'verb' => 'GET'],
95
+        ['root' => '', 'name' => 'OCS#getConfig', 'url' => '/config', 'verb' => 'GET'],
96
+        ['root' => '/person', 'name' => 'OCS#personCheck', 'url' => '/check', 'verb' => 'POST'],
97
+        ['root' => '/identityproof', 'name' => 'OCS#getIdentityProof', 'url' => '/key/{cloudId}', 'verb' => 'GET'],
98
+        ['root' => '/core', 'name' => 'Navigation#getAppsNavigation', 'url' => '/navigation/apps', 'verb' => 'GET'],
99
+        ['root' => '/core', 'name' => 'Navigation#getSettingsNavigation', 'url' => '/navigation/settings', 'verb' => 'GET'],
100
+        ['root' => '/core', 'name' => 'AutoComplete#get', 'url' => '/autocomplete/get', 'verb' => 'GET'],
101
+        ['root' => '/core', 'name' => 'WhatsNew#get', 'url' => '/whatsnew', 'verb' => 'GET'],
102
+        ['root' => '/core', 'name' => 'WhatsNew#dismiss', 'url' => '/whatsnew', 'verb' => 'POST'],
103
+        ['root' => '/core', 'name' => 'AppPassword#getAppPassword', 'url' => '/getapppassword', 'verb' => 'GET'],
104
+        ['root' => '/core', 'name' => 'AppPassword#rotateAppPassword', 'url' => '/apppassword/rotate', 'verb' => 'POST'],
105
+        ['root' => '/core', 'name' => 'AppPassword#deleteAppPassword', 'url' => '/apppassword', 'verb' => 'DELETE'],
106 106
 
107
-		['root' => '/collaboration', 'name' => 'CollaborationResources#searchCollections', 'url' => '/resources/collections/search/{filter}', 'verb' => 'GET'],
108
-		['root' => '/collaboration', 'name' => 'CollaborationResources#listCollection', 'url' => '/resources/collections/{collectionId}', 'verb' => 'GET'],
109
-		['root' => '/collaboration', 'name' => 'CollaborationResources#renameCollection', 'url' => '/resources/collections/{collectionId}', 'verb' => 'PUT'],
110
-		['root' => '/collaboration', 'name' => 'CollaborationResources#addResource', 'url' => '/resources/collections/{collectionId}', 'verb' => 'POST'],
107
+        ['root' => '/collaboration', 'name' => 'CollaborationResources#searchCollections', 'url' => '/resources/collections/search/{filter}', 'verb' => 'GET'],
108
+        ['root' => '/collaboration', 'name' => 'CollaborationResources#listCollection', 'url' => '/resources/collections/{collectionId}', 'verb' => 'GET'],
109
+        ['root' => '/collaboration', 'name' => 'CollaborationResources#renameCollection', 'url' => '/resources/collections/{collectionId}', 'verb' => 'PUT'],
110
+        ['root' => '/collaboration', 'name' => 'CollaborationResources#addResource', 'url' => '/resources/collections/{collectionId}', 'verb' => 'POST'],
111 111
 
112
-		['root' => '/collaboration', 'name' => 'CollaborationResources#removeResource', 'url' => '/resources/collections/{collectionId}', 'verb' => 'DELETE'],
113
-		['root' => '/collaboration', 'name' => 'CollaborationResources#getCollectionsByResource', 'url' => '/resources/{resourceType}/{resourceId}', 'verb' => 'GET'],
114
-		['root' => '/collaboration', 'name' => 'CollaborationResources#createCollectionOnResource', 'url' => '/resources/{baseResourceType}/{baseResourceId}', 'verb' => 'POST']
112
+        ['root' => '/collaboration', 'name' => 'CollaborationResources#removeResource', 'url' => '/resources/collections/{collectionId}', 'verb' => 'DELETE'],
113
+        ['root' => '/collaboration', 'name' => 'CollaborationResources#getCollectionsByResource', 'url' => '/resources/{resourceType}/{resourceId}', 'verb' => 'GET'],
114
+        ['root' => '/collaboration', 'name' => 'CollaborationResources#createCollectionOnResource', 'url' => '/resources/{baseResourceType}/{baseResourceId}', 'verb' => 'POST']
115 115
 
116
-	],
116
+    ],
117 117
 ]);
118 118
 
119 119
 // Post installation check
@@ -122,4 +122,4 @@  discard block
 block discarded – undo
122 122
 // Core ajax actions
123 123
 // Routing
124 124
 $this->create('core_ajax_update', '/core/ajax/update.php')
125
-	->actionInclude('core/ajax/update.php');
125
+    ->actionInclude('core/ajax/update.php');
Please login to merge, or discard this patch.
apps/files_versions/appinfo/routes.php 1 patch
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -30,19 +30,19 @@
 block discarded – undo
30 30
 /** @var Application $application */
31 31
 $application = \OC::$server->query(Application::class);
32 32
 $application->registerRoutes($this, [
33
-	'routes' => [
34
-		[
35
-			'name' => 'Preview#getPreview',
36
-			'url' => '/preview',
37
-			'verb' => 'GET',
38
-		],
39
-	],
33
+    'routes' => [
34
+        [
35
+            'name' => 'Preview#getPreview',
36
+            'url' => '/preview',
37
+            'verb' => 'GET',
38
+        ],
39
+    ],
40 40
 ]);
41 41
 
42 42
 /** @var $this \OCP\Route\IRouter */
43 43
 $this->create('files_versions_download', 'apps/files_versions/download.php')
44
-	->actionInclude('files_versions/download.php');
44
+    ->actionInclude('files_versions/download.php');
45 45
 $this->create('files_versions_ajax_getVersions', 'apps/files_versions/ajax/getVersions.php')
46
-	->actionInclude('files_versions/ajax/getVersions.php');
46
+    ->actionInclude('files_versions/ajax/getVersions.php');
47 47
 $this->create('files_versions_ajax_rollbackVersion', 'apps/files_versions/ajax/rollbackVersion.php')
48
-	->actionInclude('files_versions/ajax/rollbackVersion.php');
48
+    ->actionInclude('files_versions/ajax/rollbackVersion.php');
Please login to merge, or discard this patch.
apps/user_ldap/appinfo/routes.php 1 patch
Indentation   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -29,37 +29,37 @@
 block discarded – undo
29 29
 
30 30
 /** @var $this \OCP\Route\IRouter */
31 31
 $this->create('user_ldap_ajax_clearMappings', 'apps/user_ldap/ajax/clearMappings.php')
32
-	->actionInclude('user_ldap/ajax/clearMappings.php');
32
+    ->actionInclude('user_ldap/ajax/clearMappings.php');
33 33
 $this->create('user_ldap_ajax_deleteConfiguration', 'apps/user_ldap/ajax/deleteConfiguration.php')
34
-	->actionInclude('user_ldap/ajax/deleteConfiguration.php');
34
+    ->actionInclude('user_ldap/ajax/deleteConfiguration.php');
35 35
 $this->create('user_ldap_ajax_getConfiguration', 'apps/user_ldap/ajax/getConfiguration.php')
36
-	->actionInclude('user_ldap/ajax/getConfiguration.php');
36
+    ->actionInclude('user_ldap/ajax/getConfiguration.php');
37 37
 $this->create('user_ldap_ajax_getNewServerConfigPrefix', 'apps/user_ldap/ajax/getNewServerConfigPrefix.php')
38
-	->actionInclude('user_ldap/ajax/getNewServerConfigPrefix.php');
38
+    ->actionInclude('user_ldap/ajax/getNewServerConfigPrefix.php');
39 39
 $this->create('user_ldap_ajax_setConfiguration', 'apps/user_ldap/ajax/setConfiguration.php')
40
-	->actionInclude('user_ldap/ajax/setConfiguration.php');
40
+    ->actionInclude('user_ldap/ajax/setConfiguration.php');
41 41
 $this->create('user_ldap_ajax_testConfiguration', 'apps/user_ldap/ajax/testConfiguration.php')
42
-	->actionInclude('user_ldap/ajax/testConfiguration.php');
42
+    ->actionInclude('user_ldap/ajax/testConfiguration.php');
43 43
 $this->create('user_ldap_ajax_wizard', 'apps/user_ldap/ajax/wizard.php')
44
-	->actionInclude('user_ldap/ajax/wizard.php');
44
+    ->actionInclude('user_ldap/ajax/wizard.php');
45 45
 
46 46
 $application = new \OCP\AppFramework\App('user_ldap');
47 47
 $application->registerRoutes($this, [
48
-	'ocs' => [
49
-		['name' => 'ConfigAPI#create', 'url' => '/api/v1/config', 'verb' => 'POST'],
50
-		['name' => 'ConfigAPI#show',   'url' => '/api/v1/config/{configID}', 'verb' => 'GET'],
51
-		['name' => 'ConfigAPI#modify', 'url' => '/api/v1/config/{configID}', 'verb' => 'PUT'],
52
-		['name' => 'ConfigAPI#delete', 'url' => '/api/v1/config/{configID}', 'verb' => 'DELETE'],
53
-	]
48
+    'ocs' => [
49
+        ['name' => 'ConfigAPI#create', 'url' => '/api/v1/config', 'verb' => 'POST'],
50
+        ['name' => 'ConfigAPI#show',   'url' => '/api/v1/config/{configID}', 'verb' => 'GET'],
51
+        ['name' => 'ConfigAPI#modify', 'url' => '/api/v1/config/{configID}', 'verb' => 'PUT'],
52
+        ['name' => 'ConfigAPI#delete', 'url' => '/api/v1/config/{configID}', 'verb' => 'DELETE'],
53
+    ]
54 54
 ]);
55 55
 
56 56
 /** @var \OCA\User_LDAP\AppInfo\Application $application */
57 57
 $application = \OC::$server->query(\OCA\User_LDAP\AppInfo\Application::class);
58 58
 $application->registerRoutes($this, [
59
-	'routes' => [
60
-		['name' => 'renewPassword#tryRenewPassword', 'url' => '/renewpassword', 'verb' => 'POST'],
61
-		['name' => 'renewPassword#showRenewPasswordForm', 'url' => '/renewpassword/{user}', 'verb' => 'GET'],
62
-		['name' => 'renewPassword#cancel', 'url' => '/renewpassword/cancel', 'verb' => 'GET'],
63
-		['name' => 'renewPassword#showLoginFormInvalidPassword', 'url' => '/renewpassword/invalidlogin/{user}', 'verb' => 'GET'],
64
-	]
59
+    'routes' => [
60
+        ['name' => 'renewPassword#tryRenewPassword', 'url' => '/renewpassword', 'verb' => 'POST'],
61
+        ['name' => 'renewPassword#showRenewPasswordForm', 'url' => '/renewpassword/{user}', 'verb' => 'GET'],
62
+        ['name' => 'renewPassword#cancel', 'url' => '/renewpassword/cancel', 'verb' => 'GET'],
63
+        ['name' => 'renewPassword#showLoginFormInvalidPassword', 'url' => '/renewpassword/invalidlogin/{user}', 'verb' => 'GET'],
64
+    ]
65 65
 ]);
Please login to merge, or discard this patch.
apps/cloud_federation_api/appinfo/routes.php 1 patch
Indentation   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -22,18 +22,18 @@
 block discarded – undo
22 22
  */
23 23
 
24 24
 return [
25
-	'routes' => [
26
-		[
27
-			'name' => 'RequestHandler#addShare',
28
-			'url' => '/ocm/shares',
29
-			'verb' => 'POST',
30
-			'root' => '',
31
-		],
32
-		[
33
-			'name' => 'RequestHandler#receiveNotification',
34
-			'url' => '/ocm/notifications',
35
-			'verb' => 'POST',
36
-			'root' => '',
37
-		],
38
-	],
25
+    'routes' => [
26
+        [
27
+            'name' => 'RequestHandler#addShare',
28
+            'url' => '/ocm/shares',
29
+            'verb' => 'POST',
30
+            'root' => '',
31
+        ],
32
+        [
33
+            'name' => 'RequestHandler#receiveNotification',
34
+            'url' => '/ocm/notifications',
35
+            'verb' => 'POST',
36
+            'root' => '',
37
+        ],
38
+    ],
39 39
 ];
Please login to merge, or discard this patch.
apps/files_external/appinfo/routes.php 1 patch
Indentation   +31 added lines, -31 removed lines patch added patch discarded remove patch
@@ -30,41 +30,41 @@
 block discarded – undo
30 30
  * @var $this \OCP\Route\IRouter
31 31
  **/
32 32
 \OC_Mount_Config::$app->registerRoutes(
33
-	$this,
34
-	[
35
-		'resources' => [
36
-			'global_storages' => ['url' => '/globalstorages'],
37
-			'user_storages' => ['url' => '/userstorages'],
38
-			'user_global_storages' => ['url' => '/userglobalstorages'],
39
-		],
40
-		'routes' => [
41
-			[
42
-				'name' => 'Ajax#getSshKeys',
43
-				'url' => '/ajax/public_key.php',
44
-				'verb' => 'POST',
45
-				'requirements' => [],
46
-			],
47
-			[
48
-				'name' => 'Ajax#saveGlobalCredentials',
49
-				'url' => '/globalcredentials',
50
-				'verb' => 'POST',
51
-			],
52
-		],
53
-		'ocs' => [
54
-			[
55
-				'name' => 'Api#getUserMounts',
56
-				'url' => '/api/v1/mounts',
57
-				'verb' => 'GET',
58
-			],
59
-		],
60
-	]
33
+    $this,
34
+    [
35
+        'resources' => [
36
+            'global_storages' => ['url' => '/globalstorages'],
37
+            'user_storages' => ['url' => '/userstorages'],
38
+            'user_global_storages' => ['url' => '/userglobalstorages'],
39
+        ],
40
+        'routes' => [
41
+            [
42
+                'name' => 'Ajax#getSshKeys',
43
+                'url' => '/ajax/public_key.php',
44
+                'verb' => 'POST',
45
+                'requirements' => [],
46
+            ],
47
+            [
48
+                'name' => 'Ajax#saveGlobalCredentials',
49
+                'url' => '/globalcredentials',
50
+                'verb' => 'POST',
51
+            ],
52
+        ],
53
+        'ocs' => [
54
+            [
55
+                'name' => 'Api#getUserMounts',
56
+                'url' => '/api/v1/mounts',
57
+                'verb' => 'GET',
58
+            ],
59
+        ],
60
+    ]
61 61
 );
62 62
 
63 63
 $this->create('files_external_oauth1', 'apps/files_external/ajax/oauth1.php')
64
-	->actionInclude('files_external/ajax/oauth1.php');
64
+    ->actionInclude('files_external/ajax/oauth1.php');
65 65
 $this->create('files_external_oauth2', 'apps/files_external/ajax/oauth2.php')
66
-	->actionInclude('files_external/ajax/oauth2.php');
66
+    ->actionInclude('files_external/ajax/oauth2.php');
67 67
 
68 68
 
69 69
 $this->create('files_external_list_applicable', '/apps/files_external/applicable')
70
-	->actionInclude('files_external/ajax/applicable.php');
70
+    ->actionInclude('files_external/ajax/applicable.php');
Please login to merge, or discard this patch.
apps/files/appinfo/routes.php 1 patch
Indentation   +112 added lines, -112 removed lines patch added patch discarded remove patch
@@ -38,122 +38,122 @@
 block discarded – undo
38 38
 /** @var Application $application */
39 39
 $application = \OC::$server->query(Application::class);
40 40
 $application->registerRoutes(
41
-	$this,
42
-	[
43
-		'routes' => [
44
-			[
45
-				'name' => 'View#showFile',
46
-				'url' => '/f/{fileid}',
47
-				'verb' => 'GET',
48
-				'root' => '',
49
-			],
41
+    $this,
42
+    [
43
+        'routes' => [
44
+            [
45
+                'name' => 'View#showFile',
46
+                'url' => '/f/{fileid}',
47
+                'verb' => 'GET',
48
+                'root' => '',
49
+            ],
50 50
 
51
-			[
52
-				'name' => 'API#getThumbnail',
53
-				'url' => '/api/v1/thumbnail/{x}/{y}/{file}',
54
-				'verb' => 'GET',
55
-				'requirements' => ['file' => '.+']
56
-			],
57
-			[
58
-				'name' => 'API#updateFileTags',
59
-				'url' => '/api/v1/files/{path}',
60
-				'verb' => 'POST',
61
-				'requirements' => ['path' => '.+'],
62
-			],
63
-			[
64
-				'name' => 'API#getRecentFiles',
65
-				'url' => '/api/v1/recent/',
66
-				'verb' => 'GET'
67
-			],
68
-			[
69
-				'name' => 'API#updateFileSorting',
70
-				'url' => '/api/v1/sorting',
71
-				'verb' => 'POST'
72
-			],
73
-			[
74
-				'name' => 'API#showHiddenFiles',
75
-				'url' => '/api/v1/showhidden',
76
-				'verb' => 'POST'
77
-			],
78
-			[
79
-				'name' => 'API#showGridView',
80
-				'url' => '/api/v1/showgridview',
81
-				'verb' => 'POST'
82
-			],
83
-			[
84
-				'name' => 'API#getGridView',
85
-				'url' => '/api/v1/showgridview',
86
-				'verb' => 'GET'
87
-			],
88
-			[
89
-				'name' => 'view#index',
90
-				'url' => '/',
91
-				'verb' => 'GET',
92
-			],
93
-			[
94
-				'name' => 'ajax#getStorageStats',
95
-				'url' => '/ajax/getstoragestats.php',
96
-				'verb' => 'GET',
97
-			],
98
-			[
99
-				'name' => 'API#toggleShowFolder',
100
-				'url' => '/api/v1/toggleShowFolder/{key}',
101
-				'verb' => 'POST'
102
-			],
103
-			[
104
-				'name' => 'API#getNodeType',
105
-				'url' => '/api/v1/quickaccess/get/NodeType',
106
-				'verb' => 'GET',
107
-			],
108
-			[
109
-				'name' => 'DirectEditingView#edit',
110
-				'url' => '/directEditing/{token}',
111
-				'verb' => 'GET'
112
-			],
113
-		],
114
-		'ocs' => [
115
-			[
116
-				'name' => 'DirectEditing#info',
117
-				'url' => '/api/v1/directEditing',
118
-				'verb' => 'GET'
119
-			],
120
-			[
121
-				'name' => 'DirectEditing#templates',
122
-				'url' => '/api/v1/directEditing/templates/{editorId}/{creatorId}',
123
-				'verb' => 'GET'
124
-			],
125
-			[
126
-				'name' => 'DirectEditing#open',
127
-				'url' => '/api/v1/directEditing/open',
128
-				'verb' => 'POST'
129
-			],
130
-			[
131
-				'name' => 'DirectEditing#create',
132
-				'url' => '/api/v1/directEditing/create',
133
-				'verb' => 'POST'
134
-			],
135
-			[
136
-				'name' => 'TransferOwnership#transfer',
137
-				'url' => '/api/v1/transferownership',
138
-				'verb' => 'POST',
139
-			],
140
-			[
141
-				'name' => 'TransferOwnership#accept',
142
-				'url' => '/api/v1/transferownership/{id}',
143
-				'verb' => 'POST',
144
-			],
145
-			[
146
-				'name' => 'TransferOwnership#reject',
147
-				'url' => '/api/v1/transferownership/{id}',
148
-				'verb' => 'DELETE',
149
-			],
150
-		],
151
-	]
51
+            [
52
+                'name' => 'API#getThumbnail',
53
+                'url' => '/api/v1/thumbnail/{x}/{y}/{file}',
54
+                'verb' => 'GET',
55
+                'requirements' => ['file' => '.+']
56
+            ],
57
+            [
58
+                'name' => 'API#updateFileTags',
59
+                'url' => '/api/v1/files/{path}',
60
+                'verb' => 'POST',
61
+                'requirements' => ['path' => '.+'],
62
+            ],
63
+            [
64
+                'name' => 'API#getRecentFiles',
65
+                'url' => '/api/v1/recent/',
66
+                'verb' => 'GET'
67
+            ],
68
+            [
69
+                'name' => 'API#updateFileSorting',
70
+                'url' => '/api/v1/sorting',
71
+                'verb' => 'POST'
72
+            ],
73
+            [
74
+                'name' => 'API#showHiddenFiles',
75
+                'url' => '/api/v1/showhidden',
76
+                'verb' => 'POST'
77
+            ],
78
+            [
79
+                'name' => 'API#showGridView',
80
+                'url' => '/api/v1/showgridview',
81
+                'verb' => 'POST'
82
+            ],
83
+            [
84
+                'name' => 'API#getGridView',
85
+                'url' => '/api/v1/showgridview',
86
+                'verb' => 'GET'
87
+            ],
88
+            [
89
+                'name' => 'view#index',
90
+                'url' => '/',
91
+                'verb' => 'GET',
92
+            ],
93
+            [
94
+                'name' => 'ajax#getStorageStats',
95
+                'url' => '/ajax/getstoragestats.php',
96
+                'verb' => 'GET',
97
+            ],
98
+            [
99
+                'name' => 'API#toggleShowFolder',
100
+                'url' => '/api/v1/toggleShowFolder/{key}',
101
+                'verb' => 'POST'
102
+            ],
103
+            [
104
+                'name' => 'API#getNodeType',
105
+                'url' => '/api/v1/quickaccess/get/NodeType',
106
+                'verb' => 'GET',
107
+            ],
108
+            [
109
+                'name' => 'DirectEditingView#edit',
110
+                'url' => '/directEditing/{token}',
111
+                'verb' => 'GET'
112
+            ],
113
+        ],
114
+        'ocs' => [
115
+            [
116
+                'name' => 'DirectEditing#info',
117
+                'url' => '/api/v1/directEditing',
118
+                'verb' => 'GET'
119
+            ],
120
+            [
121
+                'name' => 'DirectEditing#templates',
122
+                'url' => '/api/v1/directEditing/templates/{editorId}/{creatorId}',
123
+                'verb' => 'GET'
124
+            ],
125
+            [
126
+                'name' => 'DirectEditing#open',
127
+                'url' => '/api/v1/directEditing/open',
128
+                'verb' => 'POST'
129
+            ],
130
+            [
131
+                'name' => 'DirectEditing#create',
132
+                'url' => '/api/v1/directEditing/create',
133
+                'verb' => 'POST'
134
+            ],
135
+            [
136
+                'name' => 'TransferOwnership#transfer',
137
+                'url' => '/api/v1/transferownership',
138
+                'verb' => 'POST',
139
+            ],
140
+            [
141
+                'name' => 'TransferOwnership#accept',
142
+                'url' => '/api/v1/transferownership/{id}',
143
+                'verb' => 'POST',
144
+            ],
145
+            [
146
+                'name' => 'TransferOwnership#reject',
147
+                'url' => '/api/v1/transferownership/{id}',
148
+                'verb' => 'DELETE',
149
+            ],
150
+        ],
151
+    ]
152 152
 );
153 153
 
154 154
 /** @var $this \OC\Route\Router */
155 155
 
156 156
 $this->create('files_ajax_download', 'apps/files/ajax/download.php')
157
-	->actionInclude('files/ajax/download.php');
157
+    ->actionInclude('files/ajax/download.php');
158 158
 $this->create('files_ajax_list', 'apps/files/ajax/list.php')
159
-	->actionInclude('files/ajax/list.php');
159
+    ->actionInclude('files/ajax/list.php');
Please login to merge, or discard this patch.
apps/files_sharing/appinfo/routes.php 1 patch
Indentation   +156 added lines, -156 removed lines patch added patch discarded remove patch
@@ -26,169 +26,169 @@
 block discarded – undo
26 26
  */
27 27
 
28 28
 return [
29
-	'resources' => [
30
-		'ExternalShares' => ['url' => '/api/externalShares'],
31
-	],
32
-	'routes' => [
33
-		[
34
-			'name' => 'Share#showShare',
35
-			'url' => '/s/{token}',
36
-			'verb' => 'GET',
37
-			'root' => '',
38
-		],
39
-		[
40
-			'name' => 'Share#showAuthenticate',
41
-			'url' => '/s/{token}/authenticate/{redirect}',
42
-			'verb' => 'GET',
43
-			'root' => '',
44
-		],
45
-		[
46
-			'name' => 'Share#authenticate',
47
-			'url' => '/s/{token}/authenticate/{redirect}',
48
-			'verb' => 'POST',
49
-			'root' => '',
50
-		],
51
-		[
52
-			'name' => 'Share#downloadShare',
53
-			'url' => '/s/{token}/download',
54
-			'verb' => 'GET',
55
-			'root' => '',
56
-		],
57
-		[
58
-			'name' => 'PublicPreview#directLink',
59
-			'url' => '/s/{token}/preview',
60
-			'verb' => 'GET',
61
-			'root' => '',
62
-		],
29
+    'resources' => [
30
+        'ExternalShares' => ['url' => '/api/externalShares'],
31
+    ],
32
+    'routes' => [
33
+        [
34
+            'name' => 'Share#showShare',
35
+            'url' => '/s/{token}',
36
+            'verb' => 'GET',
37
+            'root' => '',
38
+        ],
39
+        [
40
+            'name' => 'Share#showAuthenticate',
41
+            'url' => '/s/{token}/authenticate/{redirect}',
42
+            'verb' => 'GET',
43
+            'root' => '',
44
+        ],
45
+        [
46
+            'name' => 'Share#authenticate',
47
+            'url' => '/s/{token}/authenticate/{redirect}',
48
+            'verb' => 'POST',
49
+            'root' => '',
50
+        ],
51
+        [
52
+            'name' => 'Share#downloadShare',
53
+            'url' => '/s/{token}/download',
54
+            'verb' => 'GET',
55
+            'root' => '',
56
+        ],
57
+        [
58
+            'name' => 'PublicPreview#directLink',
59
+            'url' => '/s/{token}/preview',
60
+            'verb' => 'GET',
61
+            'root' => '',
62
+        ],
63 63
 
64
-		[
65
-			'name' => 'externalShares#testRemote',
66
-			'url' => '/testremote',
67
-			'verb' => 'GET'
68
-		],
69
-		[
70
-			'name' => 'PublicPreview#getPreview',
71
-			'url' => '/publicpreview/{token}',
72
-			'verb' => 'GET',
73
-		],
74
-		[
75
-			'name' => 'ShareInfo#info',
76
-			'url' => '/shareinfo',
77
-			'verb' => 'POST',
78
-		],
79
-		[
80
-			'name' => 'Settings#setDefaultAccept',
81
-			'url' => '/settings/defaultAccept',
82
-			'verb' => 'PUT',
83
-		],
84
-		[
85
-			'name' => 'Accept#accept',
86
-			'url' => '/accept/{shareId}',
87
-			'verb' => 'GET',
88
-		],
89
-	],
90
-	'ocs' => [
91
-		/*
64
+        [
65
+            'name' => 'externalShares#testRemote',
66
+            'url' => '/testremote',
67
+            'verb' => 'GET'
68
+        ],
69
+        [
70
+            'name' => 'PublicPreview#getPreview',
71
+            'url' => '/publicpreview/{token}',
72
+            'verb' => 'GET',
73
+        ],
74
+        [
75
+            'name' => 'ShareInfo#info',
76
+            'url' => '/shareinfo',
77
+            'verb' => 'POST',
78
+        ],
79
+        [
80
+            'name' => 'Settings#setDefaultAccept',
81
+            'url' => '/settings/defaultAccept',
82
+            'verb' => 'PUT',
83
+        ],
84
+        [
85
+            'name' => 'Accept#accept',
86
+            'url' => '/accept/{shareId}',
87
+            'verb' => 'GET',
88
+        ],
89
+    ],
90
+    'ocs' => [
91
+        /*
92 92
 		 * OCS Share API
93 93
 		 */
94
-		[
95
-			'name' => 'ShareAPI#getShares',
96
-			'url'  => '/api/v1/shares',
97
-			'verb' => 'GET',
98
-		],
99
-		[
100
-			'name' => 'ShareAPI#getInheritedShares',
101
-			'url'  => '/api/v1/shares/inherited',
102
-			'verb' => 'GET',
103
-		],
104
-		[
105
-			'name' => 'ShareAPI#createShare',
106
-			'url'  => '/api/v1/shares',
107
-			'verb' => 'POST',
108
-		],
109
-		[
110
-			'name' => 'ShareAPI#pendingShares',
111
-			'url'  => '/api/v1/shares/pending',
112
-			'verb' => 'GET',
113
-		],
114
-		[
115
-			'name' => 'ShareAPI#getShare',
116
-			'url'  => '/api/v1/shares/{id}',
117
-			'verb' => 'GET',
118
-		],
119
-		[
120
-			'name' => 'ShareAPI#updateShare',
121
-			'url'  => '/api/v1/shares/{id}',
122
-			'verb' => 'PUT',
123
-		],
124
-		[
125
-			'name' => 'ShareAPI#deleteShare',
126
-			'url'  => '/api/v1/shares/{id}',
127
-			'verb' => 'DELETE',
128
-		],
129
-		[
130
-			'name' => 'ShareAPI#acceptShare',
131
-			'url'  => '/api/v1/shares/pending/{id}',
132
-			'verb' => 'POST',
133
-		],
134
-		/*
94
+        [
95
+            'name' => 'ShareAPI#getShares',
96
+            'url'  => '/api/v1/shares',
97
+            'verb' => 'GET',
98
+        ],
99
+        [
100
+            'name' => 'ShareAPI#getInheritedShares',
101
+            'url'  => '/api/v1/shares/inherited',
102
+            'verb' => 'GET',
103
+        ],
104
+        [
105
+            'name' => 'ShareAPI#createShare',
106
+            'url'  => '/api/v1/shares',
107
+            'verb' => 'POST',
108
+        ],
109
+        [
110
+            'name' => 'ShareAPI#pendingShares',
111
+            'url'  => '/api/v1/shares/pending',
112
+            'verb' => 'GET',
113
+        ],
114
+        [
115
+            'name' => 'ShareAPI#getShare',
116
+            'url'  => '/api/v1/shares/{id}',
117
+            'verb' => 'GET',
118
+        ],
119
+        [
120
+            'name' => 'ShareAPI#updateShare',
121
+            'url'  => '/api/v1/shares/{id}',
122
+            'verb' => 'PUT',
123
+        ],
124
+        [
125
+            'name' => 'ShareAPI#deleteShare',
126
+            'url'  => '/api/v1/shares/{id}',
127
+            'verb' => 'DELETE',
128
+        ],
129
+        [
130
+            'name' => 'ShareAPI#acceptShare',
131
+            'url'  => '/api/v1/shares/pending/{id}',
132
+            'verb' => 'POST',
133
+        ],
134
+        /*
135 135
 		 * Deleted Shares
136 136
 		 */
137
-		[
138
-			'name' => 'DeletedShareAPI#index',
139
-			'url'  => '/api/v1/deletedshares',
140
-			'verb' => 'GET',
141
-		],
142
-		[
143
-			'name' => 'DeletedShareAPI#undelete',
144
-			'url'  => '/api/v1/deletedshares/{id}',
145
-			'verb' => 'POST',
146
-		],
147
-		/*
137
+        [
138
+            'name' => 'DeletedShareAPI#index',
139
+            'url'  => '/api/v1/deletedshares',
140
+            'verb' => 'GET',
141
+        ],
142
+        [
143
+            'name' => 'DeletedShareAPI#undelete',
144
+            'url'  => '/api/v1/deletedshares/{id}',
145
+            'verb' => 'POST',
146
+        ],
147
+        /*
148 148
 		 * OCS Sharee API
149 149
 		 */
150
-		[
151
-			'name' => 'ShareesAPI#search',
152
-			'url' => '/api/v1/sharees',
153
-			'verb' => 'GET',
154
-		],
155
-		[
156
-			'name' => 'ShareesAPI#findRecommended',
157
-			'url' => '/api/v1/sharees_recommended',
158
-			'verb' => 'GET',
159
-		],
160
-		/*
150
+        [
151
+            'name' => 'ShareesAPI#search',
152
+            'url' => '/api/v1/sharees',
153
+            'verb' => 'GET',
154
+        ],
155
+        [
156
+            'name' => 'ShareesAPI#findRecommended',
157
+            'url' => '/api/v1/sharees_recommended',
158
+            'verb' => 'GET',
159
+        ],
160
+        /*
161 161
 		 * Remote Shares
162 162
 		 */
163
-		[
164
-			'name' => 'Remote#getShares',
165
-			'url' => '/api/v1/remote_shares',
166
-			'verb' => 'GET',
167
-		],
168
-		[
169
-			'name' => 'Remote#getOpenShares',
170
-			'url' => '/api/v1/remote_shares/pending',
171
-			'verb' => 'GET',
172
-		],
173
-		[
174
-			'name' => 'Remote#acceptShare',
175
-			'url' => '/api/v1/remote_shares/pending/{id}',
176
-			'verb' => 'POST',
177
-		],
178
-		[
179
-			'name' => 'Remote#declineShare',
180
-			'url' => '/api/v1/remote_shares/pending/{id}',
181
-			'verb' => 'DELETE',
182
-		],
183
-		[
184
-			'name' => 'Remote#getShare',
185
-			'url' => '/api/v1/remote_shares/{id}',
186
-			'verb' => 'GET',
187
-		],
188
-		[
189
-			'name' => 'Remote#unshare',
190
-			'url' => '/api/v1/remote_shares/{id}',
191
-			'verb' => 'DELETE',
192
-		],
193
-	],
163
+        [
164
+            'name' => 'Remote#getShares',
165
+            'url' => '/api/v1/remote_shares',
166
+            'verb' => 'GET',
167
+        ],
168
+        [
169
+            'name' => 'Remote#getOpenShares',
170
+            'url' => '/api/v1/remote_shares/pending',
171
+            'verb' => 'GET',
172
+        ],
173
+        [
174
+            'name' => 'Remote#acceptShare',
175
+            'url' => '/api/v1/remote_shares/pending/{id}',
176
+            'verb' => 'POST',
177
+        ],
178
+        [
179
+            'name' => 'Remote#declineShare',
180
+            'url' => '/api/v1/remote_shares/pending/{id}',
181
+            'verb' => 'DELETE',
182
+        ],
183
+        [
184
+            'name' => 'Remote#getShare',
185
+            'url' => '/api/v1/remote_shares/{id}',
186
+            'verb' => 'GET',
187
+        ],
188
+        [
189
+            'name' => 'Remote#unshare',
190
+            'url' => '/api/v1/remote_shares/{id}',
191
+            'verb' => 'DELETE',
192
+        ],
193
+    ],
194 194
 ];
Please login to merge, or discard this patch.
apps/files_sharing/lib/AppInfo/Application.php 2 patches
Indentation   +171 added lines, -171 removed lines patch added patch discarded remove patch
@@ -60,175 +60,175 @@
 block discarded – undo
60 60
 use Symfony\Component\EventDispatcher\GenericEvent;
61 61
 
62 62
 class Application extends App {
63
-	public const APP_ID = 'files_sharing';
64
-
65
-	public function __construct(array $urlParams = []) {
66
-		parent::__construct(self::APP_ID, $urlParams);
67
-
68
-		$container = $this->getContainer();
69
-
70
-		/** @var IServerContainer $server */
71
-		$server = $container->getServer();
72
-
73
-		/** @var IEventDispatcher $dispatcher */
74
-		$dispatcher = $container->query(IEventDispatcher::class);
75
-		$mountProviderCollection = $server->getMountProviderCollection();
76
-		$notifications = $server->getNotificationManager();
77
-
78
-		/**
79
-		 * Core class wrappers
80
-		 */
81
-		$container->registerService(Manager::class, function (SimpleContainer $c) use ($server) {
82
-			$user = $server->getUserSession()->getUser();
83
-			$uid = $user ? $user->getUID() : null;
84
-			return new \OCA\Files_Sharing\External\Manager(
85
-				$server->getDatabaseConnection(),
86
-				\OC\Files\Filesystem::getMountManager(),
87
-				\OC\Files\Filesystem::getLoader(),
88
-				$server->getHTTPClientService(),
89
-				$server->getNotificationManager(),
90
-				$server->query(\OCP\OCS\IDiscoveryService::class),
91
-				$server->getCloudFederationProviderManager(),
92
-				$server->getCloudFederationFactory(),
93
-				$server->getGroupManager(),
94
-				$server->getUserManager(),
95
-				$uid
96
-			);
97
-		});
98
-
99
-		/**
100
-		 * Middleware
101
-		 */
102
-		$container->registerMiddleWare(SharingCheckMiddleware::class);
103
-		$container->registerMiddleWare(OCSShareAPIMiddleware::class);
104
-		$container->registerMiddleWare(ShareInfoMiddleware::class);
105
-
106
-		$container->registerService('ExternalMountProvider', function (IContainer $c) {
107
-			/** @var \OCP\IServerContainer $server */
108
-			$server = $c->query('ServerContainer');
109
-			return new \OCA\Files_Sharing\External\MountProvider(
110
-				$server->getDatabaseConnection(),
111
-				function () use ($c) {
112
-					return $c->query(Manager::class);
113
-				},
114
-				$server->getCloudIdManager()
115
-			);
116
-		});
117
-
118
-		/**
119
-		 * Register capabilities
120
-		 */
121
-		$container->registerCapability(Capabilities::class);
122
-
123
-		$notifications->registerNotifierService(Notifier::class);
124
-
125
-		$this->registerMountProviders($mountProviderCollection);
126
-		$this->registerEventsScripts($dispatcher);
127
-		$this->setupSharingMenus();
128
-
129
-		/**
130
-		 * Always add main sharing script
131
-		 */
132
-		Util::addScript(self::APP_ID, 'dist/main');
133
-	}
134
-
135
-	protected function registerMountProviders(IMountProviderCollection $mountProviderCollection) {
136
-		$mountProviderCollection->registerProvider($this->getContainer()->query(MountProvider::class));
137
-		$mountProviderCollection->registerProvider($this->getContainer()->query('ExternalMountProvider'));
138
-	}
139
-
140
-	protected function registerEventsScripts(IEventDispatcher $dispatcher) {
141
-		// sidebar and files scripts
142
-		$dispatcher->addServiceListener(LoadAdditionalScriptsEvent::class, LoadAdditionalListener::class);
143
-		$dispatcher->addServiceListener(LoadSidebar::class, LoadSidebarListener::class);
144
-		$dispatcher->addServiceListener(ShareCreatedEvent::class, ShareInteractionListener::class);
145
-		$dispatcher->addListener('\OCP\Collaboration\Resources::loadAdditionalScripts', function () {
146
-			\OCP\Util::addScript('files_sharing', 'dist/collaboration');
147
-		});
148
-		$dispatcher->addServiceListener(ShareCreatedEvent::class, UserShareAcceptanceListener::class);
149
-		$dispatcher->addServiceListener(UserAddedEvent::class, UserAddedToGroupListener::class);
150
-
151
-		// notifications api to accept incoming user shares
152
-		$dispatcher->addListener('OCP\Share::postShare', function (GenericEvent $event) {
153
-			/** @var Listener $listener */
154
-			$listener = $this->getContainer()->query(Listener::class);
155
-			$listener->shareNotification($event);
156
-		});
157
-		$dispatcher->addListener(IGroup::class . '::postAddUser', function (GenericEvent $event) {
158
-			/** @var Listener $listener */
159
-			$listener = $this->getContainer()->query(Listener::class);
160
-			$listener->userAddedToGroup($event);
161
-		});
162
-	}
163
-
164
-	protected function setupSharingMenus() {
165
-		$config = \OC::$server->getConfig();
166
-		$l = \OC::$server->getL10N('files_sharing');
167
-
168
-		if ($config->getAppValue('core', 'shareapi_enabled', 'yes') !== 'yes') {
169
-			return;
170
-		}
171
-
172
-		$sharingSublistArray = [];
173
-
174
-		if (\OCP\Util::isSharingDisabledForUser() === false) {
175
-			array_push($sharingSublistArray, [
176
-				'id' => 'sharingout',
177
-				'appname' => 'files_sharing',
178
-				'script' => 'list.php',
179
-				'order' => 16,
180
-				'name' => $l->t('Shared with others'),
181
-			]);
182
-		}
183
-
184
-		array_push($sharingSublistArray, [
185
-			'id' => 'sharingin',
186
-			'appname' => 'files_sharing',
187
-			'script' => 'list.php',
188
-			'order' => 15,
189
-			'name' => $l->t('Shared with you'),
190
-		]);
191
-
192
-		if (\OCP\Util::isSharingDisabledForUser() === false) {
193
-			// Check if sharing by link is enabled
194
-			if ($config->getAppValue('core', 'shareapi_allow_links', 'yes') === 'yes') {
195
-				array_push($sharingSublistArray, [
196
-					'id' => 'sharinglinks',
197
-					'appname' => 'files_sharing',
198
-					'script' => 'list.php',
199
-					'order' => 17,
200
-					'name' => $l->t('Shared by link'),
201
-				]);
202
-			}
203
-		}
204
-
205
-		array_push($sharingSublistArray, [
206
-			'id' => 'deletedshares',
207
-			'appname' => 'files_sharing',
208
-			'script' => 'list.php',
209
-			'order' => 19,
210
-			'name' => $l->t('Deleted shares'),
211
-		]);
212
-
213
-		array_push($sharingSublistArray, [
214
-			'id' => 'pendingshares',
215
-			'appname' => 'files_sharing',
216
-			'script' => 'list.php',
217
-			'order' => 19,
218
-			'name' => $l->t('Pending shares'),
219
-		]);
220
-
221
-
222
-		// show_Quick_Access stored as string
223
-		\OCA\Files\App::getNavigationManager()->add([
224
-			'id' => 'shareoverview',
225
-			'appname' => 'files_sharing',
226
-			'script' => 'list.php',
227
-			'order' => 18,
228
-			'name' => $l->t('Shares'),
229
-			'classes' => 'collapsible',
230
-			'sublist' => $sharingSublistArray,
231
-			'expandedState' => 'show_sharing_menu'
232
-		]);
233
-	}
63
+    public const APP_ID = 'files_sharing';
64
+
65
+    public function __construct(array $urlParams = []) {
66
+        parent::__construct(self::APP_ID, $urlParams);
67
+
68
+        $container = $this->getContainer();
69
+
70
+        /** @var IServerContainer $server */
71
+        $server = $container->getServer();
72
+
73
+        /** @var IEventDispatcher $dispatcher */
74
+        $dispatcher = $container->query(IEventDispatcher::class);
75
+        $mountProviderCollection = $server->getMountProviderCollection();
76
+        $notifications = $server->getNotificationManager();
77
+
78
+        /**
79
+         * Core class wrappers
80
+         */
81
+        $container->registerService(Manager::class, function (SimpleContainer $c) use ($server) {
82
+            $user = $server->getUserSession()->getUser();
83
+            $uid = $user ? $user->getUID() : null;
84
+            return new \OCA\Files_Sharing\External\Manager(
85
+                $server->getDatabaseConnection(),
86
+                \OC\Files\Filesystem::getMountManager(),
87
+                \OC\Files\Filesystem::getLoader(),
88
+                $server->getHTTPClientService(),
89
+                $server->getNotificationManager(),
90
+                $server->query(\OCP\OCS\IDiscoveryService::class),
91
+                $server->getCloudFederationProviderManager(),
92
+                $server->getCloudFederationFactory(),
93
+                $server->getGroupManager(),
94
+                $server->getUserManager(),
95
+                $uid
96
+            );
97
+        });
98
+
99
+        /**
100
+         * Middleware
101
+         */
102
+        $container->registerMiddleWare(SharingCheckMiddleware::class);
103
+        $container->registerMiddleWare(OCSShareAPIMiddleware::class);
104
+        $container->registerMiddleWare(ShareInfoMiddleware::class);
105
+
106
+        $container->registerService('ExternalMountProvider', function (IContainer $c) {
107
+            /** @var \OCP\IServerContainer $server */
108
+            $server = $c->query('ServerContainer');
109
+            return new \OCA\Files_Sharing\External\MountProvider(
110
+                $server->getDatabaseConnection(),
111
+                function () use ($c) {
112
+                    return $c->query(Manager::class);
113
+                },
114
+                $server->getCloudIdManager()
115
+            );
116
+        });
117
+
118
+        /**
119
+         * Register capabilities
120
+         */
121
+        $container->registerCapability(Capabilities::class);
122
+
123
+        $notifications->registerNotifierService(Notifier::class);
124
+
125
+        $this->registerMountProviders($mountProviderCollection);
126
+        $this->registerEventsScripts($dispatcher);
127
+        $this->setupSharingMenus();
128
+
129
+        /**
130
+         * Always add main sharing script
131
+         */
132
+        Util::addScript(self::APP_ID, 'dist/main');
133
+    }
134
+
135
+    protected function registerMountProviders(IMountProviderCollection $mountProviderCollection) {
136
+        $mountProviderCollection->registerProvider($this->getContainer()->query(MountProvider::class));
137
+        $mountProviderCollection->registerProvider($this->getContainer()->query('ExternalMountProvider'));
138
+    }
139
+
140
+    protected function registerEventsScripts(IEventDispatcher $dispatcher) {
141
+        // sidebar and files scripts
142
+        $dispatcher->addServiceListener(LoadAdditionalScriptsEvent::class, LoadAdditionalListener::class);
143
+        $dispatcher->addServiceListener(LoadSidebar::class, LoadSidebarListener::class);
144
+        $dispatcher->addServiceListener(ShareCreatedEvent::class, ShareInteractionListener::class);
145
+        $dispatcher->addListener('\OCP\Collaboration\Resources::loadAdditionalScripts', function () {
146
+            \OCP\Util::addScript('files_sharing', 'dist/collaboration');
147
+        });
148
+        $dispatcher->addServiceListener(ShareCreatedEvent::class, UserShareAcceptanceListener::class);
149
+        $dispatcher->addServiceListener(UserAddedEvent::class, UserAddedToGroupListener::class);
150
+
151
+        // notifications api to accept incoming user shares
152
+        $dispatcher->addListener('OCP\Share::postShare', function (GenericEvent $event) {
153
+            /** @var Listener $listener */
154
+            $listener = $this->getContainer()->query(Listener::class);
155
+            $listener->shareNotification($event);
156
+        });
157
+        $dispatcher->addListener(IGroup::class . '::postAddUser', function (GenericEvent $event) {
158
+            /** @var Listener $listener */
159
+            $listener = $this->getContainer()->query(Listener::class);
160
+            $listener->userAddedToGroup($event);
161
+        });
162
+    }
163
+
164
+    protected function setupSharingMenus() {
165
+        $config = \OC::$server->getConfig();
166
+        $l = \OC::$server->getL10N('files_sharing');
167
+
168
+        if ($config->getAppValue('core', 'shareapi_enabled', 'yes') !== 'yes') {
169
+            return;
170
+        }
171
+
172
+        $sharingSublistArray = [];
173
+
174
+        if (\OCP\Util::isSharingDisabledForUser() === false) {
175
+            array_push($sharingSublistArray, [
176
+                'id' => 'sharingout',
177
+                'appname' => 'files_sharing',
178
+                'script' => 'list.php',
179
+                'order' => 16,
180
+                'name' => $l->t('Shared with others'),
181
+            ]);
182
+        }
183
+
184
+        array_push($sharingSublistArray, [
185
+            'id' => 'sharingin',
186
+            'appname' => 'files_sharing',
187
+            'script' => 'list.php',
188
+            'order' => 15,
189
+            'name' => $l->t('Shared with you'),
190
+        ]);
191
+
192
+        if (\OCP\Util::isSharingDisabledForUser() === false) {
193
+            // Check if sharing by link is enabled
194
+            if ($config->getAppValue('core', 'shareapi_allow_links', 'yes') === 'yes') {
195
+                array_push($sharingSublistArray, [
196
+                    'id' => 'sharinglinks',
197
+                    'appname' => 'files_sharing',
198
+                    'script' => 'list.php',
199
+                    'order' => 17,
200
+                    'name' => $l->t('Shared by link'),
201
+                ]);
202
+            }
203
+        }
204
+
205
+        array_push($sharingSublistArray, [
206
+            'id' => 'deletedshares',
207
+            'appname' => 'files_sharing',
208
+            'script' => 'list.php',
209
+            'order' => 19,
210
+            'name' => $l->t('Deleted shares'),
211
+        ]);
212
+
213
+        array_push($sharingSublistArray, [
214
+            'id' => 'pendingshares',
215
+            'appname' => 'files_sharing',
216
+            'script' => 'list.php',
217
+            'order' => 19,
218
+            'name' => $l->t('Pending shares'),
219
+        ]);
220
+
221
+
222
+        // show_Quick_Access stored as string
223
+        \OCA\Files\App::getNavigationManager()->add([
224
+            'id' => 'shareoverview',
225
+            'appname' => 'files_sharing',
226
+            'script' => 'list.php',
227
+            'order' => 18,
228
+            'name' => $l->t('Shares'),
229
+            'classes' => 'collapsible',
230
+            'sublist' => $sharingSublistArray,
231
+            'expandedState' => 'show_sharing_menu'
232
+        ]);
233
+    }
234 234
 }
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
 		/**
79 79
 		 * Core class wrappers
80 80
 		 */
81
-		$container->registerService(Manager::class, function (SimpleContainer $c) use ($server) {
81
+		$container->registerService(Manager::class, function(SimpleContainer $c) use ($server) {
82 82
 			$user = $server->getUserSession()->getUser();
83 83
 			$uid = $user ? $user->getUID() : null;
84 84
 			return new \OCA\Files_Sharing\External\Manager(
@@ -103,12 +103,12 @@  discard block
 block discarded – undo
103 103
 		$container->registerMiddleWare(OCSShareAPIMiddleware::class);
104 104
 		$container->registerMiddleWare(ShareInfoMiddleware::class);
105 105
 
106
-		$container->registerService('ExternalMountProvider', function (IContainer $c) {
106
+		$container->registerService('ExternalMountProvider', function(IContainer $c) {
107 107
 			/** @var \OCP\IServerContainer $server */
108 108
 			$server = $c->query('ServerContainer');
109 109
 			return new \OCA\Files_Sharing\External\MountProvider(
110 110
 				$server->getDatabaseConnection(),
111
-				function () use ($c) {
111
+				function() use ($c) {
112 112
 					return $c->query(Manager::class);
113 113
 				},
114 114
 				$server->getCloudIdManager()
@@ -142,19 +142,19 @@  discard block
 block discarded – undo
142 142
 		$dispatcher->addServiceListener(LoadAdditionalScriptsEvent::class, LoadAdditionalListener::class);
143 143
 		$dispatcher->addServiceListener(LoadSidebar::class, LoadSidebarListener::class);
144 144
 		$dispatcher->addServiceListener(ShareCreatedEvent::class, ShareInteractionListener::class);
145
-		$dispatcher->addListener('\OCP\Collaboration\Resources::loadAdditionalScripts', function () {
145
+		$dispatcher->addListener('\OCP\Collaboration\Resources::loadAdditionalScripts', function() {
146 146
 			\OCP\Util::addScript('files_sharing', 'dist/collaboration');
147 147
 		});
148 148
 		$dispatcher->addServiceListener(ShareCreatedEvent::class, UserShareAcceptanceListener::class);
149 149
 		$dispatcher->addServiceListener(UserAddedEvent::class, UserAddedToGroupListener::class);
150 150
 
151 151
 		// notifications api to accept incoming user shares
152
-		$dispatcher->addListener('OCP\Share::postShare', function (GenericEvent $event) {
152
+		$dispatcher->addListener('OCP\Share::postShare', function(GenericEvent $event) {
153 153
 			/** @var Listener $listener */
154 154
 			$listener = $this->getContainer()->query(Listener::class);
155 155
 			$listener->shareNotification($event);
156 156
 		});
157
-		$dispatcher->addListener(IGroup::class . '::postAddUser', function (GenericEvent $event) {
157
+		$dispatcher->addListener(IGroup::class.'::postAddUser', function(GenericEvent $event) {
158 158
 			/** @var Listener $listener */
159 159
 			$listener = $this->getContainer()->query(Listener::class);
160 160
 			$listener->userAddedToGroup($event);
Please login to merge, or discard this patch.
ocm-provider/index.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -29,12 +29,12 @@
 block discarded – undo
29 29
 $isEnabled = $server->getAppManager()->isEnabledForUser('cloud_federation_api');
30 30
 
31 31
 if ($isEnabled) {
32
-	// Make sure the routes are loaded
33
-	\OC_App::loadApp('cloud_federation_api');
34
-	$capabilities = new OCA\CloudFederationAPI\Capabilities($server->getURLGenerator());
35
-	header('Content-Type: application/json');
36
-	echo json_encode($capabilities->getCapabilities()['ocm']);
32
+    // Make sure the routes are loaded
33
+    \OC_App::loadApp('cloud_federation_api');
34
+    $capabilities = new OCA\CloudFederationAPI\Capabilities($server->getURLGenerator());
35
+    header('Content-Type: application/json');
36
+    echo json_encode($capabilities->getCapabilities()['ocm']);
37 37
 } else {
38
-	header($_SERVER["SERVER_PROTOCOL"]." 501 Not Implemented", true, 501);
39
-	exit("501 Not Implemented");
38
+    header($_SERVER["SERVER_PROTOCOL"]." 501 Not Implemented", true, 501);
39
+    exit("501 Not Implemented");
40 40
 }
Please login to merge, or discard this patch.