Populate link_owner. Props donncha. fixes #1695
git-svn-id: http://svn.automattic.com/wordpress/trunk@2901 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
14eb9ebc01
commit
d8ea1c7db4
|
@ -565,7 +565,7 @@ function edit_link($link_id = '') {
|
|||
}
|
||||
|
||||
function wp_insert_link($linkdata) {
|
||||
global $wpdb;
|
||||
global $wpdb, $current_user;
|
||||
|
||||
extract($linkdata);
|
||||
|
||||
|
@ -580,7 +580,10 @@ function wp_insert_link($linkdata) {
|
|||
$link_target = '';
|
||||
|
||||
if ( empty($link_visible) )
|
||||
$link_visible = 'Y';
|
||||
$link_visible = 'Y';
|
||||
|
||||
if ( empty($link_owner) )
|
||||
$link_owner = $current_user->id;
|
||||
|
||||
if ( $update ) {
|
||||
$wpdb->query("UPDATE $wpdb->links SET link_url='$link_url',
|
||||
|
|
Loading…
Reference in New Issue