Authored by Rock Zhang

修复收藏的品牌或者商品,在获取后面页数接口没返回时会出现无数据提示的bug

Code Review By Rock Zhang
... ... @@ -201,7 +201,7 @@ class UserModel
$datas[] = $product;
}
!empty($datas) && $result['hasFavProduct'] = $datas;
} else if ($page > 1 && isset($favProduct['code']) && $favProduct['code'] === 500) {
} else if ($page > 1 && (!$favProduct || (isset($favProduct['code']) && $favProduct['code'] === 500))) {
$result['end'] = true;
}
... ... @@ -259,7 +259,7 @@ class UserModel
$datas[] = $brand;
}
!empty($datas) && $result['hasFavBrand'] = $datas;
} else if ($page > 1 && isset($favBrand['code']) && $favBrand['code'] === 500) {
} else if ($page > 1 && (!$favBrand || (isset($favBrand['code']) && $favBrand['code'] === 500))) {
$result['end'] = true;
}
... ...