From 58e57e1581db238a9ffd8e61f34bbcd487c9b279 Mon Sep 17 00:00:00 2001 From: thinkphp Date: Thu, 18 Feb 2016 17:49:35 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9B=E4=B8=80=E5=A4=84=E8=AD=A6?= =?UTF-8?q?=E5=91=8A=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/Model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/think/Model.php b/library/think/Model.php index 3a7853d6..6d4baae3 100644 --- a/library/think/Model.php +++ b/library/think/Model.php @@ -1177,7 +1177,7 @@ class Model protected function checkValidate($value, $val, &$data) { $rule = $val[0]; - $msg = $val[1]; + $msg = isset($val[1]) ? $val[1] : ''; $type = isset($val[2]) ? $val[2] : 'regex'; $options = isset($val[3]) ? $val[3] : []; if ($rule instanceof \Closure) {