This commit is contained in:
songliang 2023-07-15 18:52:34 +08:00
parent 2e49208872
commit f1c02e622b

View File

@ -900,7 +900,7 @@ class ShopController extends BaseAuthedController
break;
case ShopController::TOTAL_BUY_LIMIT: {
// error_log("total buy limit " . $address . " " . $id . " " . $row['limit_num']);
$buyRecord = getXVal($buyRecordHash, $id);
$buyRecord = getXVal($buyRecordHash, $goods_id);
$boughtTimes = $buyRecord ? $buyRecord['total_buy_times'] + 1 : 1;
if ($buyRecord && getXVal($buyRecord, 'total_buy_times', 0) >= $row['limit_num']) {
$this->_rspErr(2, 'Purchase limit reached');