@@ -16,13 +16,13 @@ |
||
| 16 | 16 | */ |
| 17 | 17 | public function handle($request, Closure $next, $guard = null) |
| 18 | 18 | { |
| 19 | - $ipsAuth = env('BASIC_AUTH_IP',''); |
|
| 20 | - $ipsAuth = explode(',',$ipsAuth); |
|
| 19 | + $ipsAuth = env('BASIC_AUTH_IP', ''); |
|
| 20 | + $ipsAuth = explode(',', $ipsAuth); |
|
| 21 | 21 | |
| 22 | 22 | |
| 23 | - if (env('BASIC_AUTH',false) == true) |
|
| 23 | + if (env('BASIC_AUTH', false) == true) |
|
| 24 | 24 | { |
| 25 | - if(empty($ipsAuth) || !in_array($request->ip(),$ipsAuth)) |
|
| 25 | + if (empty($ipsAuth) || !in_array($request->ip(), $ipsAuth)) |
|
| 26 | 26 | { |
| 27 | 27 | return $this->auth->guard($guard)->basic() ?: $next($request); |
| 28 | 28 | } |
@@ -17,7 +17,7 @@ discard block |
||
| 17 | 17 | */ |
| 18 | 18 | public function __construct(Application $app) |
| 19 | 19 | { |
| 20 | - $this->app = $app; |
|
| 20 | + $this->app = $app; |
|
| 21 | 21 | } |
| 22 | 22 | |
| 23 | 23 | /** |
@@ -33,7 +33,7 @@ discard block |
||
| 33 | 33 | if (UserUtils::isBackendRole()) |
| 34 | 34 | { |
| 35 | 35 | UserUtils::setDisplayAllStatus(); |
| 36 | - }else{ |
|
| 36 | + } else { |
|
| 37 | 37 | UserUtils::forgotDisplayAllStatus(); |
| 38 | 38 | } |
| 39 | 39 | |
@@ -18,8 +18,8 @@ |
||
| 18 | 18 | public function handle($request, Closure $next) |
| 19 | 19 | { |
| 20 | 20 | |
| 21 | - if($request->session()->has('language')){ |
|
| 22 | - $local = $request->session()->get('language',config('app.locale')); |
|
| 21 | + if ($request->session()->has('language')) { |
|
| 22 | + $local = $request->session()->get('language', config('app.locale')); |
|
| 23 | 23 | app()->setLocale($local); |
| 24 | 24 | } |
| 25 | 25 | |
@@ -18,7 +18,7 @@ |
||
| 18 | 18 | |
| 19 | 19 | public function getChangeLang($locale = null) |
| 20 | 20 | {
|
| 21 | - session()->set('language',$locale);
|
|
| 21 | + session()->set('language', $locale);
|
|
| 22 | 22 | app()->setLocale($locale); |
| 23 | 23 | return redirect()->back(); |
| 24 | 24 | } |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | |
| 30 | 30 | }); |
| 31 | 31 | |
| 32 | -$router->group(array('middleware' => ['auth','language']), function() use($router) |
|
| 32 | +$router->group(array('middleware' => ['auth', 'language']), function() use($router) |
|
| 33 | 33 | { |
| 34 | 34 | $router->group(array('middleware' => 'permission', 'prefix' => config('expendable.admin_base_uri')), function() use($router) |
| 35 | 35 | { |