diff options
author | Evan Prodromou <evan@status.net> | 2010-10-14 01:35:11 -0400 |
---|---|---|
committer | Evan Prodromou <evan@status.net> | 2010-10-14 01:35:11 -0400 |
commit | 97a7fb246c8de9a2cf1bfc38ca275a13e9c40f58 (patch) | |
tree | 984b1e3b3a55b01ba7956f849453abaffc83fd6b /lib | |
parent | 7fb765b2cb0be47236ad3fbf625f908dd5da8f47 (diff) |
correctly use sslserver if it is set
Diffstat (limited to 'lib')
-rw-r--r-- | lib/htmloutputter.php | 7 | ||||
-rw-r--r-- | lib/theme.php | 7 |
2 files changed, 12 insertions, 2 deletions
diff --git a/lib/htmloutputter.php b/lib/htmloutputter.php index f01f1814f..4a1b7db47 100644 --- a/lib/htmloutputter.php +++ b/lib/htmloutputter.php @@ -371,7 +371,12 @@ class HTMLOutputter extends XMLOutputter $sslserver = common_config('javascript', 'sslserver'); if (empty($sslserver)) { - $server = common_config('site', 'server'); + if (is_string(common_config('site', 'sslserver')) && + mb_strlen(common_config('site', 'sslserver')) > 0) { + $server = common_config('site', 'sslserver'); + } else if (common_config('site', 'server')) { + $server = common_config('site', 'server'); + } $path = common_config('site', 'path') . '/js/'; } else { $server = $sslserver; diff --git a/lib/theme.php b/lib/theme.php index 669d9a19f..95b7c1de4 100644 --- a/lib/theme.php +++ b/lib/theme.php @@ -121,7 +121,12 @@ class Theme $sslserver = common_config($group, 'sslserver'); if (empty($sslserver)) { - $server = common_config('site', 'server'); + if (is_string(common_config('site', 'sslserver')) && + mb_strlen(common_config('site', 'sslserver')) > 0) { + $server = common_config('site', 'sslserver'); + } else if (common_config('site', 'server')) { + $server = common_config('site', 'server'); + } $path = common_config('site', 'path') . '/'; if ($fallbackSubdir) { $path .= $fallbackSubdir . '/'; |