function nw_com_update($story_id, $total_num){ $story_id = intval($story_id); $total_num = intval($total_num); $article = new nw_NewsStory($story_id); if (!$article->updateComments($total_num)) { return false; } return true; }