Expanded the middleware test

This commit is contained in:
stanjg 2018-06-01 16:22:06 +02:00
parent e9ac014bf4
commit b56f3a8671
No known key found for this signature in database
GPG key ID: 27D9DF9D28935303
2 changed files with 18 additions and 3 deletions

View file

@ -48,7 +48,7 @@ class LanguageMiddleware
*/
public function handle(Request $request, Closure $next)
{
$this->app->setLocale($request->user()->language ?? $this->config->get('app.locale'));
$this->app->setLocale($request->user()->language ?? $this->config->get('app.locale', 'en'));
return $next($request);
}