From ae0df81c421a59f573c3c70c072749267014e302 Mon Sep 17 00:00:00 2001 From: thinkphp Date: Sun, 6 Mar 2016 22:41:47 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/Validate.php | 2 +- tests/thinkphp/library/think/validateTest.php | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/library/think/Validate.php b/library/think/Validate.php index 89128f2f..69189ce4 100644 --- a/library/think/Validate.php +++ b/library/think/Validate.php @@ -27,7 +27,7 @@ class Validate ]; // 验证失败错误信息 - protected static $error = []; + protected static $error = null; /** * 设置正则验证规则 diff --git a/tests/thinkphp/library/think/validateTest.php b/tests/thinkphp/library/think/validateTest.php index 7f184440..0d445971 100644 --- a/tests/thinkphp/library/think/validateTest.php +++ b/tests/thinkphp/library/think/validateTest.php @@ -10,7 +10,7 @@ // +---------------------------------------------------------------------- /** - * 模型类测试 + * Validate类测试 */ namespace tests\thinkphp\library\think; @@ -119,7 +119,6 @@ class validateTest extends \PHPUnit_Framework_TestCase 'password' => ['md5', 'callback'], 'nickname' => [[ & $this, 'fillName'], 'callback', 'cn_'], 'phone' => function ($value, $data) { - echo $value; return trim($value); }, 'ab' => ['a,b', 'serialize'],