@@ -88,5 +88,5 @@ |
||
88 | 88 | |
89 | 89 | abstract public function getRequest(); |
90 | 90 | |
91 | - abstract protected function config($string, $children = []); |
|
91 | + abstract protected function config($string, $children = [ ]); |
|
92 | 92 | } |
@@ -13,7 +13,7 @@ discard block |
||
13 | 13 | /** |
14 | 14 | * Make a JSON response. |
15 | 15 | * |
16 | - * @param $statusCode |
|
16 | + * @param integer $statusCode |
|
17 | 17 | * |
18 | 18 | * @return IlluminateJsonResponse |
19 | 19 | */ |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | /** |
42 | 42 | * Make a web response. |
43 | 43 | * |
44 | - * @param $statusCode |
|
44 | + * @param integer $statusCode |
|
45 | 45 | * |
46 | 46 | * @return \Illuminate\Http\Response |
47 | 47 | */ |
@@ -98,5 +98,10 @@ discard block |
||
98 | 98 | |
99 | 99 | abstract public function getRequest(); |
100 | 100 | |
101 | + /** |
|
102 | + * @param string $string |
|
103 | + * |
|
104 | + * @return string|null |
|
105 | + */ |
|
101 | 106 | abstract protected function config($string, $children = []); |
102 | 107 | } |
@@ -88,5 +88,5 @@ |
||
88 | 88 | |
89 | 89 | abstract public function getRequest(); |
90 | 90 | |
91 | - abstract protected function config($string, $children = []); |
|
91 | + abstract protected function config($string, $children = [ ]); |
|
92 | 92 | } |
@@ -35,5 +35,5 @@ |
||
35 | 35 | return $this->getAuth()->user(); |
36 | 36 | } |
37 | 37 | |
38 | - abstract public function config($string, $children = []); |
|
38 | + abstract public function config($string, $children = [ ]); |
|
39 | 39 | } |
@@ -18,7 +18,7 @@ |
||
18 | 18 | } |
19 | 19 | |
20 | 20 | return config( |
21 | - implode('.', [Constants::CONFIG_PACKAGE_NAME, $string]), |
|
21 | + implode('.', [ Constants::CONFIG_PACKAGE_NAME, $string ]), |
|
22 | 22 | $default |
23 | 23 | ); |
24 | 24 | } |
@@ -92,7 +92,7 @@ |
||
92 | 92 | return $this; |
93 | 93 | } |
94 | 94 | |
95 | - abstract protected function config($string, $children = []); |
|
95 | + abstract protected function config($string, $children = [ ]); |
|
96 | 96 | |
97 | 97 | abstract public function getRequest(); |
98 | 98 | } |
@@ -33,7 +33,7 @@ |
||
33 | 33 | */ |
34 | 34 | public function register() |
35 | 35 | { |
36 | - $this->app->singleton('pragmarx.google2fa', function ($app) { |
|
36 | + $this->app->singleton('pragmarx.google2fa', function($app) { |
|
37 | 37 | return $app->make(Google2FA::class); |
38 | 38 | }); |
39 | 39 | } |
@@ -37,7 +37,7 @@ |
||
37 | 37 | return $this->createErrorBagForMessage( |
38 | 38 | trans( |
39 | 39 | config( |
40 | - array_key_exists($statusCode, $errorMap) ? $errorMap[$statusCode] : 'google2fa.error_messages.unknown' |
|
40 | + array_key_exists($statusCode, $errorMap) ? $errorMap[ $statusCode ] : 'google2fa.error_messages.unknown' |
|
41 | 41 | ) |
42 | 42 | ) |
43 | 43 | ); |
@@ -204,7 +204,7 @@ discard block |
||
204 | 204 | return |
205 | 205 | ( |
206 | 206 | (bool) $this->sessionGet(Constants::SESSION_AUTH_PASSED, false) || |
207 | - ( $this->config('remember') && $this->getUser()->{$this->config('remember_column')} && ( Carbon::now() <= (new Carbon($this->getUser()->{$this->config('remember_column')}))->addMinutes($this->config('lifetime')) ) ) |
|
207 | + ($this->config('remember') && $this->getUser()->{$this->config('remember_column')} && (Carbon::now() <= (new Carbon($this->getUser()->{$this->config('remember_column')}))->addMinutes($this->config('lifetime')))) |
|
208 | 208 | ) && |
209 | 209 | !$this->passwordExpired(); |
210 | 210 | } |
@@ -226,7 +226,7 @@ discard block |
||
226 | 226 | { |
227 | 227 | $this->sessionPut(Constants::SESSION_AUTH_PASSED, true); |
228 | 228 | |
229 | - if (isset(\Cookie::get()[\Auth::getRecallerName()])) { |
|
229 | + if (isset(\Cookie::get()[ \Auth::getRecallerName() ])) { |
|
230 | 230 | $user = $this->getUser(); |
231 | 231 | $user->{$this->config('remember_column')} = Carbon::now(); |
232 | 232 | $user->save(); |