diff --git a/app/Services/OptionForm.php b/app/Services/OptionForm.php index 8b8b2c0f..2703dfa2 100644 --- a/app/Services/OptionForm.php +++ b/app/Services/OptionForm.php @@ -71,10 +71,7 @@ class OptionForm // Assign name for option item if (! isset($params[1]) || Arr::get($params, 1) == OptionForm::AUTO_DETECT) { - $params[1] = trans("options.$this->id.$params[0]"); - if ($params[1] == "options.$this->id.$params[0]") { - $params[1] = trans("options.$this->id.$params[0].title"); - } + $params[1] = Arr::get(trans("options.$this->id.$params[0]"), 'title', trans("options.$this->id.$params[0]")); } $class = new ReflectionClass('App\Services\OptionForm'.Str::title($method)); diff --git a/config/yaml-translation.php b/config/yaml-translation.php index 1bc781e2..aa95818e 100644 --- a/config/yaml-translation.php +++ b/config/yaml-translation.php @@ -11,5 +11,5 @@ return [ | If true, this will flatten all array contents into a string. */ - 'dot_syntax' => true, + 'dot_syntax' => false, ];