--- uc_auction.module 2011-09-26 16:45:14.000000000 -0600 +++ uc_auction.module 2011-10-06 11:38:35.000000000 -0600 @@ -726,14 +605,13 @@ function uc_auction_nodeapi(&$node, $op, } } - - if (!$auc['high_bid']) { + if (!$auc['high_bid_amt']) { $auc['high_bid_amt'] = $auc['start_price']; } else { /* workaround for fixing false @@ -742,7 +620,7 @@ function uc_auction_nodeapi(&$node, $op, // We're calculating these bid limits here so that other modules can // override them in their on hook_nodeapi()s later. - $auc['min_bid'] = $auc['high_bid_amt'] + ($auc['min_increase'] !== NULL ? $auc['min_increase'] : variable_get('uc_auction_min_increase', .5)); + $auc['min_bid'] = $auc['high_bid_amt'] + ($auc['min_increase'] !== NULL ? $auc['high_bid_amt'] + $auc['min_increase'] : variable_get('uc_auction_min_increase', .5)); if ($auc['max_inc'] === NULL) { $auc['max_inc'] = variable_get('uc_auction_max_increase', 1000); } @@ -1186,6 +1064,11 @@ function uc_auction_bid_table_form_valid // fetch min-bid $db_data = db_query("SELECT MAX(amount) as amount FROM {uc_auction_bids} WHERE nid = '%s'" , $form_state['values']['nid']); $db_data = db_fetch_object($db_data); + // use the 'start_price' if there are no bids yet + if(!$db_data->amount) { + $db_data = db_query("SELECT start_price as amount FROM {uc_auction} WHERE nid = '%s'", $form_state['values']['nid']); + $db_data = db_fetch_object($db_data); + } // TODO: Check that the submitted bid value will fit in the DB? $form_state['values']['user_bid'] = _uc_auction_uncurrency($form_state['values']['user_bid']);