diff --git a/webapp/controller/ActivityController.class.php b/webapp/controller/ActivityController.class.php index cf2ebda..563241b 100644 --- a/webapp/controller/ActivityController.class.php +++ b/webapp/controller/ActivityController.class.php @@ -442,18 +442,18 @@ class ActivityController{ } if ($cur_cost > 0) { - $row = $conn->execQueryOne( + $userrow = $conn->execQueryOne( 'SELECT diamond_num, first_gift, free_coin, free_diamond FROM user WHERE accountid=:accountid;', array( ':accountid' => $account_id ) ); - if (!$row) { + if (!$userrow) { phpcommon\sendError(ERR_USER_BASE + 1, '没有这个玩家'); return; } //扣除钻石 - if ($row['diamond_num'] < $cur_cost) { + if ($userrow['diamond_num'] < $cur_cost) { phpcommon\sendError(ERR_USER_BASE + 3, '钻石不足'); return; }