aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/includes/functions.php')
-rw-r--r--phpBB/includes/functions.php12
1 files changed, 4 insertions, 8 deletions
diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php
index 6a36210dca..2cd62d7bac 100644
--- a/phpBB/includes/functions.php
+++ b/phpBB/includes/functions.php
@@ -1644,7 +1644,7 @@ function append_sid($url, $params = false, $is_amp = true, $session_id = false,
*/
function generate_board_url($without_script_path = false)
{
- global $config, $user, $request;
+ global $config, $user, $request, $symfony_request;
$server_name = $user->host;
@@ -1661,7 +1661,8 @@ function generate_board_url($without_script_path = false)
}
else
{
- $server_port = $request->server('SERVER_PORT', 0);
+ $server_port = (int) $symfony_request->getPort();
+
$forwarded_proto = $request->server('HTTP_X_FORWARDED_PROTO');
if (!empty($forwarded_proto) && $forwarded_proto === 'https')
@@ -4069,11 +4070,6 @@ function phpbb_get_avatar($row, $alt, $ignore_config = false, $lazy = false)
if ($driver)
{
$html = $driver->get_custom_html($user, $row, $alt);
- if (!empty($html))
- {
- return $html;
- }
-
$avatar_data = $driver->get_data($row);
}
else
@@ -4081,7 +4077,7 @@ function phpbb_get_avatar($row, $alt, $ignore_config = false, $lazy = false)
$avatar_data['src'] = '';
}
- if (!empty($avatar_data['src']))
+ if (empty($html) && !empty($avatar_data['src']))
{
if ($lazy)
{