mirror of
git://develop.git.wordpress.org/
synced 2025-01-17 21:08:44 +01:00
Administration: Allow wp_update_link()
to update the link_owner
field, for consistency with other link fields.
Props pbiron, valentinbora, nikhilgupte. Fixes #41687. git-svn-id: https://develop.svn.wordpress.org/trunk@47291 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
1911d0db67
commit
ae82bd40cc
@ -203,7 +203,7 @@ function wp_insert_link( $linkdata, $wp_error = false ) {
|
||||
}
|
||||
|
||||
if ( $update ) {
|
||||
if ( false === $wpdb->update( $wpdb->links, compact( 'link_url', 'link_name', 'link_image', 'link_target', 'link_description', 'link_visible', 'link_rating', 'link_rel', 'link_notes', 'link_rss' ), compact( 'link_id' ) ) ) {
|
||||
if ( false === $wpdb->update( $wpdb->links, compact( 'link_url', 'link_name', 'link_image', 'link_target', 'link_description', 'link_visible', 'link_owner', 'link_rating', 'link_rel', 'link_notes', 'link_rss' ), compact( 'link_id' ) ) ) {
|
||||
if ( $wp_error ) {
|
||||
return new WP_Error( 'db_update_error', __( 'Could not update link in the database' ), $wpdb->last_error );
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user