Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/jsxc.nextcloud.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsualko <klaus@jsxc.org>2020-07-01 15:48:14 +0300
committersualko <klaus@jsxc.org>2020-07-01 15:48:14 +0300
commite8e0528aa60e095ebbda508118bc0e983eeeebee (patch)
treefebafb4cd0584e100f6bb194d2dc5a44b2da6b94
parentf436369a3046014f0dfbc50bb235dccf77ba09d6 (diff)
fix(internal): hosts with custom port
-rw-r--r--lib/Controller/SettingsController.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Controller/SettingsController.php b/lib/Controller/SettingsController.php
index c1f85a7..3d3d9a1 100644
--- a/lib/Controller/SettingsController.php
+++ b/lib/Controller/SettingsController.php
@@ -59,12 +59,13 @@ class SettingsController extends Controller
if ($serverType === Application::INTERNAL) {
$serverHost = $this->request->getServerHost();
+ $domain = parse_url($serverHost)['host'];
$data['xmpp'] = [
- 'defaultDomain' => $serverHost,
+ 'defaultDomain' => $domain,
'url' => \OC::$server->getURLGenerator()->linkToRouteAbsolute('ojsxc.http_bind.index'),
'node' => $currentUID,
- 'domain' => $serverHost,
+ 'domain' => $domain,
'resource' => 'internal'
];