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

git-svn-id: https://develop.svn.wordpress.org/trunk@10277 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2008-12-30 22:32:43 +00:00
parent e7a5bb8295
commit c2f108aec4
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;