Handle id back compat in isset magic method. see #15458
git-svn-id: https://develop.svn.wordpress.org/trunk@18515 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
f9becd5d16
commit
afe083447f
|
@ -462,6 +462,10 @@ class WP_User {
|
|||
* @since 3.3.0
|
||||
*/
|
||||
function __isset( $key ) {
|
||||
if ( 'id' == $key ) {
|
||||
_deprecated_argument( 'WP_User->id', '2.1', __( 'Use <code>WP_User->ID</code> instead.' ) );
|
||||
$key = 'ID';
|
||||
}
|
||||
return isset( $this->data->$key );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue