From 05e22d4db851d86d9b2800a0ffee979058908a01 Mon Sep 17 00:00:00 2001 From: wuyanwen Date: Tue, 14 Jan 2020 18:32:30 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=9C=8D=E5=8A=A1=E6=B3=A8?= =?UTF-8?q?=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- catch/CatchAdminService.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/catch/CatchAdminService.php b/catch/CatchAdminService.php index 510e11b..2359360 100644 --- a/catch/CatchAdminService.php +++ b/catch/CatchAdminService.php @@ -62,9 +62,9 @@ class CatchAdminService extends Service */ protected function registerValidates(): void { - Validate::maker(function($validate) { - $validates = config('catch.validates'); + $validates = config('catch.validates'); + Validate::maker(function($validate) use ($validates) { foreach ($validates as $vali) { $vali = app()->make($vali); $validate->extend($vali->type(), [$vali, 'verify'], $vali->message());