mirror of
https://github.com/WordPress/WordPress.git
synced 2024-09-27 06:42:56 +02:00
Don't show a shortlink button if we don't have one. See #14772.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16076 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
c6491e5db4
commit
a532e1d86d
@ -170,6 +170,8 @@ function wp_admin_bar_blog_separator() {
|
||||
function wp_admin_bar_bloginfo_menu() {
|
||||
global $wp_admin_bar;
|
||||
|
||||
$short = wp_get_shortlink( 0, 'query' );
|
||||
if ( ! empty( $short) )
|
||||
$wp_admin_bar->add_menu( array( 'id' => 'get-shortlink', 'title' => __( 'Get Shortlink' ), 'href' => '', ) );
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user