diff --git a/phpBB/phpbb/avatar/manager.php b/phpBB/phpbb/avatar/manager.php index 18b198caa7..f4fc16ab52 100644 --- a/phpBB/phpbb/avatar/manager.php +++ b/phpBB/phpbb/avatar/manager.php @@ -190,7 +190,7 @@ class manager * @param array $row User data or group data * @param string $prefix Prefix of data keys (e.g. user), should not include the trailing underscore * - * @return array{string, string} User or group data with keys that have been + * @return array User or group data with keys that have been * stripped from the preceding "user_" or "group_" * Also the group id is prefixed with g, when the prefix group is removed. */ @@ -205,7 +205,7 @@ class manager $output = []; foreach ($row as $key => $value) { - $key = preg_replace("#^(?:{$prefix}_)#", '', $key); + $key = preg_replace("#^(?:{$prefix}_)#", '', (string) $key); $output[$key] = $value; }