Give titleless drafts a title in the quickpress box. Fixes #7801 props Speedboxer.

git-svn-id: http://svn.automattic.com/wordpress/trunk@9024 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
westi 2008-09-28 20:43:08 +00:00
parent 5cdac6c1a2
commit 3a0c8ef52c
1 changed files with 2 additions and 0 deletions

View File

@ -379,6 +379,8 @@ function wp_dashboard_quick_press( $sidebar_args ) {
foreach ( $drafts_query->posts as $draft ) {
$url = get_edit_post_link( $draft->ID );
$title = get_the_title( $draft->ID );
if ( empty( $title ) )
$title = __('no-title');
$list[] = "<a href='$url' title='" . sprintf( __( 'Edit "%s"' ), attribute_escape( $title ) ) . "'>$title</a>";
}
?>