From 74428eb98db5d0c7e0b4491a04c52f816b659c2c Mon Sep 17 00:00:00 2001 From: knowpia <9812993@qq.com> Date: Mon, 19 Sep 2022 16:30:28 +0800 Subject: [PATCH] fix bug --- app/controller/Share.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controller/Share.php b/app/controller/Share.php index abe5415..606de64 100644 --- a/app/controller/Share.php +++ b/app/controller/Share.php @@ -17,7 +17,7 @@ class Share $list = Db::name("app_users")->where($where)->order("share_count desc,id desc")->limit(env("PAGE_COUNT"))->select()->toArray(); foreach($list as $vo){ $result['lastIndex'] = $vo['id']; - $result['data'] = [ + $result['data'][] = [ "id"=>$vo['id'], "nickname"=>$vo['nickname'], "count"=>$vo['share_count']