From 550d019e17d395b161540c147c727411e4500213 Mon Sep 17 00:00:00 2001 From: Dmitry Khomutov Date: Sat, 18 Mar 2017 12:14:24 +0700 Subject: [PATCH] Fixed language select on user/edit page --- src/PHPCensor/Helper/Lang.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/PHPCensor/Helper/Lang.php b/src/PHPCensor/Helper/Lang.php index 893a89fa..1dbff3f7 100644 --- a/src/PHPCensor/Helper/Lang.php +++ b/src/PHPCensor/Helper/Lang.php @@ -98,8 +98,10 @@ class Lang { $languages = []; foreach (self::$languages as $language) { - $strings = include_once(SRC_DIR . 'Languages' . DIRECTORY_SEPARATOR . 'lang.' . $language . '.php'); - $languages[$language] = !empty($strings['language_name']) ? $strings['language_name'] : $language; + $strings = include(SRC_DIR . 'Languages' . DIRECTORY_SEPARATOR . 'lang.' . $language . '.php'); + $languages[$language] = !empty($strings['language_name']) + ? $strings['language_name'] . ' (' . $language . ')' + : $language; } return $languages;