提交 d74b87d6 编写于 作者: L liuyi

修复PHP版本为7.4.4及以上时无法安装的问题;

修复PHP版本为7.4.4及以上时生成小程序的错误:Unparenthesized `a ? b : c ? d : e` is deprecated. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)`
上级 c8346d7c
......@@ -78,7 +78,7 @@ class ZipFolder
*/
public function Zip($zipfile, $folder, $ignored = null)
{
$this->ignored_names = is_array($ignored) ? $ignored : $ignored ? array($ignored) : array();
$this->ignored_names = is_array($ignored) ? $ignored : ($ignored ? array($ignored) : array());
if($this->zip->open($zipfile, \ZipArchive::CREATE) !== true)
{
throw new Exception("cannot open <$zipfile>\n");
......
......@@ -565,7 +565,7 @@ class Query
$seq = (ord(substr($type($value), 0, 1)) % $rule['num']) + 1;
} else {
// 按照字段的首字母的值分表
$seq = (ord($value{0}) % $rule['num']) + 1;
$seq = (ord($value[0]) % $rule['num']) + 1;
}
}
return $this->getTable() . '_' . $seq;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册