Options, Meta APIs: Pass $meta_type to the get_{$meta_type}_metadata filter in metadata_exists().

This matches the main instance of the filter in `get_metadata_raw()`.

Follow-up to [48505].

Props pbiron, jsmoriss, TimothyBlynJacobs.
Fixes #51866.

git-svn-id: https://develop.svn.wordpress.org/trunk@49699 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2020-11-26 12:32:35 +00:00
parent 4a4d46fbe3
commit 7f547618fd

View File

@ -673,7 +673,7 @@ function metadata_exists( $meta_type, $object_id, $meta_key ) {
}
/** This filter is documented in wp-includes/meta.php */
$check = apply_filters( "get_{$meta_type}_metadata", null, $object_id, $meta_key, true );
$check = apply_filters( "get_{$meta_type}_metadata", null, $object_id, $meta_key, true, $meta_type );
if ( null !== $check ) {
return (bool) $check;
}