diff options
author | Joas Schilling <nickvergessen@gmx.de> | 2011-09-20 01:33:33 +0200 |
---|---|---|
committer | Oleg Pudeyev <oleg@bsdpower.com> | 2011-11-25 15:10:49 -0500 |
commit | 179662e949967090724c5e14ea4d4d399886a38a (patch) | |
tree | d0b584b66747a925966f521cc72ffd1824882439 /phpBB/includes/acp/acp_icons.php | |
parent | 88ae40a4b19360645d5e5a614cc378e7cce4afe3 (diff) | |
download | forums-179662e949967090724c5e14ea4d4d399886a38a.tar forums-179662e949967090724c5e14ea4d4d399886a38a.tar.gz forums-179662e949967090724c5e14ea4d4d399886a38a.tar.bz2 forums-179662e949967090724c5e14ea4d4d399886a38a.tar.xz forums-179662e949967090724c5e14ea4d4d399886a38a.zip |
[ticket/10345] Use the plural function in some more places.
I added two function avatar_explanation_string() and avatar_error_wrong_size()
for easier handling of the "pixels"-languages, as they are used quite often.
PHPBB3-10345
Diffstat (limited to 'phpBB/includes/acp/acp_icons.php')
-rw-r--r-- | phpBB/includes/acp/acp_icons.php | 20 |
1 files changed, 3 insertions, 17 deletions
diff --git a/phpBB/includes/acp/acp_icons.php b/phpBB/includes/acp/acp_icons.php index 98aef45892..e02124fb42 100644 --- a/phpBB/includes/acp/acp_icons.php +++ b/phpBB/includes/acp/acp_icons.php @@ -487,21 +487,7 @@ class acp_icons $cache->destroy('_icons'); $cache->destroy('sql', $table); - $level = E_USER_NOTICE; - switch ($icons_updated) - { - case 0: - $suc_lang = "{$lang}_NONE"; - $level = E_USER_WARNING; - break; - - case 1: - $suc_lang = "{$lang}_ONE"; - break; - - default: - $suc_lang = $lang; - } + $level = ($icons_updated) ? E_USER_NOTICE : E_USER_WARNING; $errormsgs = ''; foreach ($errors as $img => $error) { @@ -509,11 +495,11 @@ class acp_icons } if ($action == 'modify') { - trigger_error($user->lang[$suc_lang . '_EDITED'] . $errormsgs . adm_back_link($this->u_action), $level); + trigger_error($user->lang($lang . '_EDITED', $icons_updated) . $errormsgs . adm_back_link($this->u_action), $level); } else { - trigger_error($user->lang[$suc_lang . '_ADDED'] . $errormsgs . adm_back_link($this->u_action), $level); + trigger_error($user->lang($lang . '_ADDED', $icons_updated) . $errormsgs . adm_back_link($this->u_action), $level); } break; |