aboutsummaryrefslogtreecommitdiffstats
path: root/apps/updatenotification/lib
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2017-08-02 10:12:55 +0200
committerMorris Jobke <hey@morrisjobke.de>2017-08-02 13:56:36 +0200
commit9391d8fc60e452a53bb8ab0df98fa09f361015ee (patch)
tree72fd166992dc4de3de3ad39811046ef000e4a8e6 /apps/updatenotification/lib
parenta96c6519358a8f6b1d52d0e27bd099b704b22383 (diff)
downloadnextcloud-server-9391d8fc60e452a53bb8ab0df98fa09f361015ee.tar.gz
nextcloud-server-9391d8fc60e452a53bb8ab0df98fa09f361015ee.zip
Improve update notification layout and show non-default update server
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'apps/updatenotification/lib')
-rw-r--r--apps/updatenotification/lib/Controller/AdminController.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/apps/updatenotification/lib/Controller/AdminController.php b/apps/updatenotification/lib/Controller/AdminController.php
index e3139b42ed2..fd68a6dd962 100644
--- a/apps/updatenotification/lib/Controller/AdminController.php
+++ b/apps/updatenotification/lib/Controller/AdminController.php
@@ -105,6 +105,9 @@ class AdminController extends Controller implements ISettings {
$notifyGroups = json_decode($this->config->getAppValue('updatenotification', 'notify_groups', '["admin"]'), true);
+ $defaultUpdateServerURL = 'https://updates.nextcloud.com/server/';
+ $updateServerURL = $this->config->getSystemValue('updater.server.url', $defaultUpdateServerURL);
+
$params = [
'isNewVersionAvailable' => !empty($updateState['updateAvailable']),
'isUpdateChecked' => $lastUpdateCheckTimestamp > 0,
@@ -114,7 +117,8 @@ class AdminController extends Controller implements ISettings {
'newVersionString' => (empty($updateState['updateVersion'])) ? '' : $updateState['updateVersion'],
'downloadLink' => (empty($updateState['downloadLink'])) ? '' : $updateState['downloadLink'],
'updaterEnabled' => (empty($updateState['updaterEnabled'])) ? false : $updateState['updaterEnabled'],
-
+ 'isDefaultUpdateServerURL' => $updateServerURL === $defaultUpdateServerURL,
+ 'updateServerURL' => $updateServerURL,
'notify_groups' => implode('|', $notifyGroups),
];