blob: f1f737a4943de06fba102c281ea74f247cc8781a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
<?php
/**
* Copyright (c) 2013-2014, Lukas Reschke <lukas@owncloud.com>
* This file is licensed under the Affero General Public License version 3 or later.
* See the COPYING-README file.
*/
OC_Util::checkAdminUser();
OCP\JSON::callCheck();
if(isset($_POST['enforceHTTPS'])) {
\OC::$server->getConfig()->setSystemValue('forcessl', filter_var($_POST['enforceHTTPS'], FILTER_VALIDATE_BOOLEAN));
}
if(isset($_POST['trustedDomain'])) {
$trustedDomains = \OC::$server->getConfig()->getSystemValue('trusted_domains');
$trustedDomains[] = $_POST['trustedDomain'];
\OC::$server->getConfig()->setSystemValue('trusted_domains', $trustedDomains);
}
echo 'true';
|