mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-06 23:02:48 +08:00
修正验证类的布尔值规则
This commit is contained in:
@@ -591,7 +591,7 @@ class Validate
|
|||||||
break;
|
break;
|
||||||
case 'boolean':
|
case 'boolean':
|
||||||
// 是否为布尔值
|
// 是否为布尔值
|
||||||
$result = in_array($value, [0, 1, true, false]);
|
$result = in_array($value, [true, false, 0, 1, '0', '1'], true);
|
||||||
break;
|
break;
|
||||||
case 'array':
|
case 'array':
|
||||||
// 是否为数组
|
// 是否为数组
|
||||||
|
|||||||
Reference in New Issue
Block a user