|
@@ 64-67 (lines=4) @@
|
| 61 |
|
} |
| 62 |
|
|
| 63 |
|
public function getRemoteCollaboraURL($remote) { |
| 64 |
|
if ($this->trustedServers === null || !$this->trustedServers->isTrustedServer($remote)) { |
| 65 |
|
$this->logger->info('Unable to determine collabora URL of remote server ' . $remote . ' - Remote is not a trusted server'); |
| 66 |
|
return ''; |
| 67 |
|
} |
| 68 |
|
if ($remoteCollabora = $this->cache->get('richdocuments_remote/' . $remote)) { |
| 69 |
|
return $remoteCollabora; |
| 70 |
|
} |
|
@@ 107-110 (lines=4) @@
|
| 104 |
|
} |
| 105 |
|
|
| 106 |
|
public function getRemoteFileDetails($remote, $remoteToken) { |
| 107 |
|
if ($this->trustedServers === null || !$this->trustedServers->isTrustedServer($remote)) { |
| 108 |
|
$this->logger->info('Unable to determine collabora URL of remote server ' . $remote . ' - Remote is not a trusted server'); |
| 109 |
|
return null; |
| 110 |
|
} |
| 111 |
|
try { |
| 112 |
|
$client = $this->clientService->newClient(); |
| 113 |
|
$response = $client->post($remote . '/ocs/v2.php/apps/richdocuments/api/v1/federation?format=json', [ |