Fixes #3254 add ability to override existing translation validation language in App

This reverts commit eeaa9221aec4ad63bf63236bc037190fd4a36495.
This commit is contained in:
Abdul Malik Ikhsan 2020-07-09 13:37:16 +07:00
parent a18fdea70b
commit caf0fce98d
No known key found for this signature in database
GPG Key ID: 23FCCC74D1442CAE
2 changed files with 14 additions and 1 deletions

View File

@ -0,0 +1,4 @@
<?php
// override core en language system validation or define your own en language validation message
return [];

View File

@ -338,7 +338,16 @@ class Language
*/
protected function requireFile(string $path): array
{
$files = Services::locator()->search($path);
$files = Services::locator()->search($path);
$files = array_merge(
array_filter($files, function ($value) {
return strpos($value, APPPATH) === false;
}),
array_filter($files, function ($value) {
return strpos($value, APPPATH) === 0;
})
);
$strings = [];
foreach ($files as $file)