From 15f665b2b1e4403afff41e88c511c6f8d7b115e6 Mon Sep 17 00:00:00 2001 From: thinkphp Date: Wed, 24 Oct 2018 16:57:05 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9B=E9=97=AD=E5=8C=85=E9=AA=8C?= =?UTF-8?q?=E8=AF=81=E7=9A=84=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/Validate.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library/think/Validate.php b/library/think/Validate.php index 6226892c..0b97e64d 100644 --- a/library/think/Validate.php +++ b/library/think/Validate.php @@ -315,8 +315,8 @@ class Validate // 字段验证 if ($rule instanceof \Closure) { - // 匿名函数验证 支持传入当前字段和所有字段两个数据 - $result = call_user_func_array($rule, [$value, $data]); + // 匿名函数验证 + $result = call_user_func_array($rule, [$value, $data, $title, $msg, $this]); } else { $result = $this->checkItem($key, $value, $rule, $data, $title, $msg); }