summaryrefslogtreecommitdiffstats
path: root/apps/federation
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2019-11-11 12:35:55 +0100
committerGitHub <noreply@github.com>2019-11-11 12:35:55 +0100
commit323c76cd48db37fc047162367dd504c82befff6e (patch)
tree15c0d2b16147736d25b65cc987c2a5aae0c84b88 /apps/federation
parent46344870858e320787846617be55a143565b8118 (diff)
parent3c092993460fc9ad71970f4b5933f81a3666e56e (diff)
downloadnextcloud-server-323c76cd48db37fc047162367dd504c82befff6e.tar.gz
nextcloud-server-323c76cd48db37fc047162367dd504c82befff6e.zip
Merge pull request #17859 from nextcloud/bugfix/app-init
Fix app class setup warnings
Diffstat (limited to 'apps/federation')
-rw-r--r--apps/federation/appinfo/routes.php91
1 files changed, 43 insertions, 48 deletions
diff --git a/apps/federation/appinfo/routes.php b/apps/federation/appinfo/routes.php
index 065be94f36b..3d8e25ba1de 100644
--- a/apps/federation/appinfo/routes.php
+++ b/apps/federation/appinfo/routes.php
@@ -22,53 +22,48 @@
*
*/
-$application = new \OCA\Federation\AppInfo\Application();
-
-$application->registerRoutes(
- $this,
- [
- 'routes' => [
- [
- 'name' => 'Settings#addServer',
- 'url' => '/trusted-servers',
- 'verb' => 'POST'
- ],
- [
- 'name' => 'Settings#removeServer',
- 'url' => '/trusted-servers/{id}',
- 'verb' => 'DELETE'
- ],
- [
- 'name' => 'Settings#autoAddServers',
- 'url' => '/auto-add-servers',
- 'verb' => 'POST'
- ],
+return [
+ 'routes' => [
+ [
+ 'name' => 'Settings#addServer',
+ 'url' => '/trusted-servers',
+ 'verb' => 'POST'
+ ],
+ [
+ 'name' => 'Settings#removeServer',
+ 'url' => '/trusted-servers/{id}',
+ 'verb' => 'DELETE'
+ ],
+ [
+ 'name' => 'Settings#autoAddServers',
+ 'url' => '/auto-add-servers',
+ 'verb' => 'POST'
+ ],
+ ],
+ 'ocs' => [
+ // old endpoints, only used by Nextcloud and ownCloud
+ [
+ 'name' => 'OCSAuthAPI#getSharedSecretLegacy',
+ 'url' => '/api/v1/shared-secret',
+ 'verb' => 'GET',
+ ],
+ [
+ 'name' => 'OCSAuthAPI#requestSharedSecretLegacy',
+ 'url' => '/api/v1/request-shared-secret',
+ 'verb' => 'POST',
+ ],
+ // new endpoints, published as public api
+ [
+ 'name' => 'OCSAuthAPI#getSharedSecret',
+ 'root' => '/cloud',
+ 'url' => '/shared-secret',
+ 'verb' => 'GET',
],
- 'ocs' => [
- // old endpoints, only used by Nextcloud and ownCloud
- [
- 'name' => 'OCSAuthAPI#getSharedSecretLegacy',
- 'url' => '/api/v1/shared-secret',
- 'verb' => 'GET',
- ],
- [
- 'name' => 'OCSAuthAPI#requestSharedSecretLegacy',
- 'url' => '/api/v1/request-shared-secret',
- 'verb' => 'POST',
- ],
- // new endpoints, published as public api
- [
- 'name' => 'OCSAuthAPI#getSharedSecret',
- 'root' => '/cloud',
- 'url' => '/shared-secret',
- 'verb' => 'GET',
- ],
- [
- 'name' => 'OCSAuthAPI#requestSharedSecret',
- 'root' => '/cloud',
- 'url' => '/shared-secret',
- 'verb' => 'POST',
- ],
+ [
+ 'name' => 'OCSAuthAPI#requestSharedSecret',
+ 'root' => '/cloud',
+ 'url' => '/shared-secret',
+ 'verb' => 'POST',
],
- ]
-);
+ ],
+];