Don't assume page 1 when cpage is empty. Props filosofo. fixes #8630 for trunk

git-svn-id: http://svn.automattic.com/wordpress/trunk@10277 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2008-12-30 22:32:43 +00:00
parent d38dee6a4a
commit 00c2c8c19f
1 changed files with 1 additions and 7 deletions

View File

@ -1261,9 +1261,6 @@ function get_next_comments_link( $label = '', $max_page = 0 ) {
$page = get_query_var('cpage');
if ( !$page )
$page = 1;
$nextpage = intval($page) + 1;
if ( empty($max_page) )
@ -1307,10 +1304,7 @@ function get_previous_comments_link( $label = '' ) {
$page = get_query_var('cpage');
if ( !$page )
$page = 1;
if ( $page <= 1 )
if ( intval($page) <= 1 )
return;
$prevpage = intval($page) - 1;