Browse Source

dynamic languagefile search

1Day 3 years ago
parent
commit
4f67108606
1 changed files with 2 additions and 1 deletions
  1. 2 1
      config/app.php

+ 2 - 1
config/app.php

@@ -97,7 +97,8 @@ return [
     |
     |
     */
     */
 
 
-    'available_locales' =>["en","cs","de","es","fr","hi","it","nl","pl","zh"],
+    'available_locales' => array_map('basename', preg_replace('/\\.[^.\\s]{3,4}$/', '', glob(resource_path()."/lang/*.json", GLOB_BRACE))),
+
 
 
     /*
     /*
     |--------------------------------------------------------------------------
     |--------------------------------------------------------------------------