Commit 5a471c60 5a471c6071834d7640ce3f8acec3eaca787c07f2 by 杨俊

fix(develop): 修复报错

1 parent 91722542
......@@ -90,7 +90,7 @@ public function bandList(Request $request)
$data = $query->get(['id']);
//插入有序集合中
Redis::client()->del($key);
Redis::client()->zAdd($key, ...$data->map(fn(Project $item) => [random_int(50, 200), $item->getKey()])->flatten()->toArray());
Redis::client()->zAdd($key, ...$data->map(fn(Project $item) => [random_int(50, 200), $item->getKey()])->flatten()->toArray() ?? []);
Redis::client()->expire($key, 2 * 60 * 60);
}
$recommendIds = Redis::client()->zRevRange($key, $startIndex, $endIndex);
......