Changeset 53842 for trunk/src/wp-includes/revision.php
- Timestamp:
- 08/05/2022 01:37:47 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/revision.php
r53841 r53842 604 604 } 605 605 606 $revisions = wp_get_ post_revisions( $post->ID, array( 'posts_per_page' => 1 ));607 608 if ( 0 === count( $revisions )) {606 $revisions = wp_get_latest_revision_id_and_total_count( $post->ID ); 607 608 if ( is_wp_error( $revisions ) || 0 === $revisions['count'] ) { 609 609 return null; 610 610 } 611 611 612 $revision = reset( $revisions ); 613 return get_edit_post_link( $revision ); 612 return get_edit_post_link( $revisions['latest_id'] ); 614 613 } 615 614
Note: See TracChangeset
for help on using the changeset viewer.