1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-13 04:04:12 +02:00

[feature/avatars] Add function for localizing errors

PHPBB3-10018
This commit is contained in:
Marc Alexander
2013-01-06 21:09:07 +01:00
parent 111e02395c
commit 41710c745d
5 changed files with 35 additions and 58 deletions

View File

@@ -674,19 +674,7 @@ class ucp_groups
}
// Merge any avatars errors into the primary error array
// Drivers use lang constants, so we need to map to the actual strings
foreach ($avatar_error as $lang)
{
if (is_array($lang))
{
$key = array_shift($lang);
$error[] = vsprintf($user->lang($key), $lang);
}
else
{
$error[] = $user->lang("$lang");
}
}
$error = array_merge($error, $phpbb_avatar_manager->localize_errors($user, $avatar_error));
$template->assign_vars(array(
'S_EDIT' => true,