FEATURE: language switch works - changes translations
This commit is contained in:
@@ -4,6 +4,7 @@ use App\Models\File;
|
||||
use App\Models\Language;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
use Mcamara\LaravelLocalization\Facades\LaravelLocalization;
|
||||
use Symfony\Component\Translation\Translator;
|
||||
|
||||
class LaravelLocalizationServiceProvider extends ServiceProvider
|
||||
@@ -28,4 +29,8 @@ class LaravelLocalizationServiceProvider extends ServiceProvider
|
||||
'laravellocalization.hideDefaultLocaleInURL' => true
|
||||
]);
|
||||
}
|
||||
|
||||
public function boot() {
|
||||
\App::setLocale(LaravelLocalization::setLocale());
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user