Don't show "Link added." in link-add.php if an empty form was submitted. fixes #12262.

git-svn-id: http://svn.automattic.com/wordpress/trunk@13960 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
nacin 2010-04-03 07:48:30 +00:00
parent 647fe5d199
commit 65d12646e1

View File

@ -67,9 +67,11 @@ switch ($action) {
case 'add' :
check_admin_referer('add-bookmark');
add_link();
$redir = wp_get_referer();
if ( add_link() )
$redir = add_query_arg( 'added', 'true', $redir );
wp_redirect( wp_get_referer() . '?added=true' );
wp_redirect( $redir );
exit;
break;