From d84bee506360e4eb7da6d80537a9dbdb2a83611f Mon Sep 17 00:00:00 2001 From: David Anderson Date: Fri, 13 Mar 2015 12:42:50 -0700 Subject: [PATCH] web: bug fixes in server_status.php --- html/user/server_status.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/html/user/server_status.php b/html/user/server_status.php index 2095a846bd..0bbd5c108b 100644 --- a/html/user/server_status.php +++ b/html/user/server_status.php @@ -264,8 +264,8 @@ function get_daemon_status() { } $daemons = $c->daemons; $config = $c->config; - $main_host = (string)$config->host; - $master_url = (string)$config->master_url; + $main_host = trim((string)$config->host); + $master_url = trim((string)$config->master_url); $u = parse_url($master_url); if (!array_key_exists("host", $u)) { print_r($u); @@ -273,7 +273,7 @@ function get_daemon_status() { } $master_host = $u["host"]; if ($config->www_host) { - $web_host = (string) $config->www_host; + $web_host = trim((string) $config->www_host); } else { $web_host = $main_host; } @@ -283,7 +283,7 @@ function get_daemon_status() { // the upload and download servers are sort of daemons too // - $url = (string) $config->download_url; + $url = trim((string) $config->download_url); $u = parse_url($url); $h = $u["host"]; if ($h == $master_host) { @@ -295,7 +295,7 @@ function get_daemon_status() { } else { $have_remote = true; } - $url = (string) $config->upload_url; + $url = trim((string) $config->upload_url); $u = parse_url($url); $h = $u["host"]; if ($h == $master_host) {