Editor: Link suggestions: add fallback title for posts with no title.
Fixes #42664. Built from https://develop.svn.wordpress.org/trunk@42425 git-svn-id: http://core.svn.wordpress.org/trunk@42256 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -468,8 +468,11 @@
|
||||
}
|
||||
}
|
||||
} ).autocomplete( 'instance' )._renderItem = function( ul, item ) {
|
||||
var fallbackTitle = ( typeof window.wpLinkL10n !== 'undefined' ) ? window.wpLinkL10n.noTitle : '',
|
||||
title = item.title ? item.title : fallbackTitle;
|
||||
|
||||
return $( '<li role="option" id="mce-wp-autocomplete-' + item.ID + '">' )
|
||||
.append( '<span>' + item.title + '</span> <span class="wp-editor-float-right">' + item.info + '</span>' )
|
||||
.append( '<span>' + title + '</span> <span class="wp-editor-float-right">' + item.info + '</span>' )
|
||||
.appendTo( ul );
|
||||
};
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
Binary file not shown.
@@ -4,7 +4,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.0-alpha-42424';
|
||||
$wp_version = '5.0-alpha-42425';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
||||
Reference in New Issue
Block a user