Changeset 36158 for branches/4.4/src/wp-includes/comment-template.php
- Timestamp:
- 01/03/2016 02:06:04 AM (9 years ago)
- Location:
- branches/4.4
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/4.4
-
branches/4.4/src/wp-includes/comment-template.php
r36041 r36158 1925 1925 */ 1926 1926 $r = apply_filters( 'wp_list_comments_args', $r ); 1927 1928 /* 1929 * If 'page' or 'per_page' has been passed, and does not match what's in $wp_query, 1930 * perform a separate comment query and allow Walker_Comment to paginate. 1931 */ 1932 if ( is_singular() && ( $r['page'] || $r['per_page'] ) ) { 1933 $current_cpage = get_query_var( 'cpage' ); 1934 if ( ! $current_cpage ) { 1935 $current_cpage = 'newest' === get_option( 'default_comments_page' ) ? 1 : $wp_query->max_num_comment_pages; 1936 } 1937 1938 $current_per_page = get_query_var( 'comments_per_page' ); 1939 if ( $r['page'] != $current_cpage || $r['per_page'] != $current_per_page ) { 1940 $comments = get_comments( array( 1941 'post_id' => get_queried_object_id(), 1942 'orderby' => 'comment_date_gmt', 1943 'order' => 'ASC', 1944 'status' => 'all', 1945 ) ); 1946 } 1947 } 1927 1948 1928 1949 // Figure out what comments we'll be looping through ($_comments)
Note: See TracChangeset
for help on using the changeset viewer.