aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/profilefields/lang_helper.php
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@gmx.de>2014-01-16 16:00:52 +0100
committerJoas Schilling <nickvergessen@gmx.de>2014-01-16 16:00:52 +0100
commit0bdec35cd4127cd4f1e96b9a77340580c6045423 (patch)
treef3ca5142aa20113fb2ddbad620efd792e6cbb43e /phpBB/phpbb/profilefields/lang_helper.php
parent78603bb96d0afa0695b296013dec17485d74ea45 (diff)
downloadforums-0bdec35cd4127cd4f1e96b9a77340580c6045423.tar
forums-0bdec35cd4127cd4f1e96b9a77340580c6045423.tar.gz
forums-0bdec35cd4127cd4f1e96b9a77340580c6045423.tar.bz2
forums-0bdec35cd4127cd4f1e96b9a77340580c6045423.tar.xz
forums-0bdec35cd4127cd4f1e96b9a77340580c6045423.zip
[ticket/11201] Move grabbing the input of the language options to type class
PHPBB3-11201
Diffstat (limited to 'phpBB/phpbb/profilefields/lang_helper.php')
-rw-r--r--phpBB/phpbb/profilefields/lang_helper.php10
1 files changed, 9 insertions, 1 deletions
diff --git a/phpBB/phpbb/profilefields/lang_helper.php b/phpBB/phpbb/profilefields/lang_helper.php
index 627c76e76e..569eaaca40 100644
--- a/phpBB/phpbb/profilefields/lang_helper.php
+++ b/phpBB/phpbb/profilefields/lang_helper.php
@@ -48,6 +48,14 @@ class lang_helper
foreach ($lang_options as $num => $var)
{
+ if (!isset($this->options_lang[$field_id]))
+ {
+ $this->options_lang[$field_id] = array();
+ }
+ if (!isset($this->options_lang[$field_id][$lang_id]))
+ {
+ $this->options_lang[$field_id][$lang_id] = array();
+ }
$this->options_lang[$field_id][$lang_id][($num + 1)] = $var;
}
}
@@ -104,7 +112,7 @@ class lang_helper
*/
public function get($field_id, $lang_id, $field_value = null)
{
- if (!is_null($field_value))
+ if (is_null($field_value))
{
return $this->options_lang[$field_id][$lang_id];
}