diff --git a/wp-includes/meta.php b/wp-includes/meta.php
index ff32086..f9cf57b 100644
|
a
|
b
|
function registered_meta_key_exists( $object_type, $object_subtype, $meta_key ) |
| 1131 | 1131 | return false; |
| 1132 | 1132 | } |
| 1133 | 1133 | |
| 1134 | | // Only specific core object types are supported. |
| 1135 | 1134 | if ( ! wp_object_type_exists( $object_type ) ) { |
| 1136 | | return new WP_Error( 'invalid_meta_key', __( 'Invalid meta key. Not a core object type.' ) ); |
| | 1135 | return false; |
| 1137 | 1136 | } |
| 1138 | 1137 | |
| 1139 | 1138 | if ( ! isset( $wp_meta_keys[ $object_type ] ) ) { |
| … |
… |
function registered_meta_key_exists( $object_type, $object_subtype, $meta_key ) |
| 1165 | 1164 | function unregister_meta_key( $object_type, $object_subtype, $meta_key ) { |
| 1166 | 1165 | global $wp_meta_keys; |
| 1167 | 1166 | |
| | 1167 | // Only specific core object types are supported. |
| | 1168 | if ( ! wp_object_type_exists( $object_type ) ) { |
| | 1169 | return new WP_Error( 'invalid_meta_key', __( 'Invalid meta key. Not a core object type.' ) ); |
| | 1170 | } |
| | 1171 | |
| 1168 | 1172 | if ( ! registered_meta_key_exists( $object_type, $object_subtype, $meta_key ) ) { |
| 1169 | 1173 | return new WP_Error( 'invalid_meta_key', __( 'Invalid meta key' ) ); |
| 1170 | 1174 | } |