mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-12 03:34:04 +02:00
[feature/avatars] Implement better treatment of avatar errors
PHPBB3-10018
This commit is contained in:
@@ -656,18 +656,16 @@ class ucp_profile
|
||||
}
|
||||
|
||||
// Replace "error" strings with their real, localised form
|
||||
$err = $error;
|
||||
$error = array();
|
||||
foreach ($err as $e)
|
||||
foreach ($error as $key => $lang)
|
||||
{
|
||||
if (is_array($e))
|
||||
if (is_array($lang))
|
||||
{
|
||||
$key = array_shift($e);
|
||||
$error[] = vsprintf($user->lang($key), $e);
|
||||
$key = array_shift($lang);
|
||||
$error[$key] = vsprintf($user->lang($key), $lang);
|
||||
}
|
||||
else
|
||||
{
|
||||
$error[] = $user->lang((string) $e);
|
||||
$error[$key] = $user->lang("$lang");
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user