Updated default language path (#1390)

* Updated default language path

* Calculated path instead of building string version

* Removed whitespace in function call
This commit is contained in:
notian 2018-03-26 13:03:10 -04:00 committed by Marcus Bointon
parent 4fd6207768
commit 58fa10db27
1 changed files with 1 additions and 1 deletions

View File

@ -1994,7 +1994,7 @@ class PHPMailer
];
if (empty($lang_path)) {
// Calculate an absolute path so it can work if CWD is not here
$lang_path = __DIR__ . DIRECTORY_SEPARATOR . 'language' . DIRECTORY_SEPARATOR;
$lang_path = dirname(__DIR__) . DIRECTORY_SEPARATOR . 'language' . DIRECTORY_SEPARATOR;
}
//Validate $langcode
if (!preg_match('/^[a-z]{2}(?:_[a-zA-Z]{2})?$/', $langcode)) {