diff options
author | Evan Prodromou <evan@status.net> | 2009-10-31 12:16:30 -0400 |
---|---|---|
committer | Evan Prodromou <evan@status.net> | 2009-10-31 12:16:30 -0400 |
commit | 5e27d53947ff64c8aee1b2287e1c77bbeaea51f7 (patch) | |
tree | baf10735ebc98827820844e8ec9d616061ab645b /lib/util.php | |
parent | 65a3ccd4587193bba72501837fab097e041f96d3 (diff) | |
parent | dcca9fbec0cea9c5e15c4d58a8e9870514dfdbdd (diff) |
Merge branch '0.8.x' into testing
Diffstat (limited to 'lib/util.php')
-rw-r--r-- | lib/util.php | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/util.php b/lib/util.php index 047faeef0..0052090f6 100644 --- a/lib/util.php +++ b/lib/util.php @@ -760,12 +760,18 @@ function common_path($relative, $ssl=false) if (is_string(common_config('site', 'sslserver')) && mb_strlen(common_config('site', 'sslserver')) > 0) { $serverpart = common_config('site', 'sslserver'); - } else { + } else if (common_config('site', 'server')) { $serverpart = common_config('site', 'server'); + } else { + common_log(LOG_ERR, 'Site Sever not configured, unable to determine site name.'); } } else { $proto = 'http'; - $serverpart = common_config('site', 'server'); + if (common_config('site', 'server')) { + $serverpart = common_config('site', 'server'); + } else { + common_log(LOG_ERR, 'Site Sever not configured, unable to determine site name.'); + } } return $proto.'://'.$serverpart.'/'.$pathpart.$relative; |