@@ -33,7 +33,7 @@ |
||
| 33 | 33 | |
| 34 | 34 | /** |
| 35 | 35 | * 获取图片验证码的URL |
| 36 | - * @param null $name |
|
| 36 | + * @param string|null $name |
|
| 37 | 37 | * @return string |
| 38 | 38 | */ |
| 39 | 39 | public static function src($name = null) |
@@ -51,7 +51,7 @@ discard block |
||
| 51 | 51 | $path = config('captcha.path'); |
| 52 | 52 | } |
| 53 | 53 | |
| 54 | - app('router')->get($path, function (Request $request) { |
|
| 54 | + app('router')->get($path, function(Request $request) { |
|
| 55 | 55 | |
| 56 | 56 | $name = $request->get('name'); |
| 57 | 57 | |
@@ -82,7 +82,7 @@ discard block |
||
| 82 | 82 | public static function validations() |
| 83 | 83 | { |
| 84 | 84 | // Validator extensions |
| 85 | - app('validator')->extend('captcha', function ($attribute, $value, array $parameters = []) { |
|
| 85 | + app('validator')->extend('captcha', function($attribute, $value, array $parameters = []) { |
|
| 86 | 86 | |
| 87 | 87 | return app('captcha')->check($value, array_first($parameters)); |
| 88 | 88 | }); |
@@ -41,7 +41,7 @@ |
||
| 41 | 41 | $this->mergeConfigFrom(__DIR__ . '/../../config/captcha.php', 'captcha'); |
| 42 | 42 | |
| 43 | 43 | //注册到容器中 |
| 44 | - $this->app->singleton('captcha', function () { |
|
| 44 | + $this->app->singleton('captcha', function() { |
|
| 45 | 45 | |
| 46 | 46 | $config = config('captcha', array()); |
| 47 | 47 | |
@@ -97,7 +97,7 @@ |
||
| 97 | 97 | } |
| 98 | 98 | |
| 99 | 99 | //返回验证结果 |
| 100 | - return strtolower($input) == $this->get($name);//password_verify(strtolower($input), $this->get($name)); |
|
| 100 | + return strtolower($input) == $this->get($name); //password_verify(strtolower($input), $this->get($name)); |
|
| 101 | 101 | } |
| 102 | 102 | |
| 103 | 103 | /** |