Browse Source

Make sure the cloud_federation_api routes are loaded

Signed-off-by: Joas Schilling <coding@schilljs.com>
tags/v19.0.0beta5
Joas Schilling 4 years ago
parent
commit
6332d7c0b3
No account linked to committer's email address
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      ocm-provider/index.php

+ 2
- 0
ocm-provider/index.php View File

@@ -29,6 +29,8 @@ $server = \OC::$server;
$isEnabled = $server->getAppManager()->isEnabledForUser('cloud_federation_api');

if ($isEnabled) {
// Make sure the routes are loaded
\OC_App::loadApp('cloud_federation_api');
$capabilities = new OCA\CloudFederationAPI\Capabilities($server->getURLGenerator());
header('Content-Type: application/json');
echo json_encode($capabilities->getCapabilities()['ocm']);

Loading…
Cancel
Save