Make WordPress Core

Ticket #22746: meta.2.diff

File meta.2.diff, 470 bytes (added by xknown, 11 years ago)

Updated patch. Cast to bool to match the metadata_exists() documentation.

  • src/wp-includes/meta.php

    function metadata_exists( $meta_type, $object_id, $meta_key ) { 
    323323
    324324        $check = apply_filters( "get_{$meta_type}_metadata", null, $object_id, $meta_key, true );
    325325        if ( null !== $check )
    326                 return true;
     326                return (bool) $check;
    327327
    328328        $meta_cache = wp_cache_get( $object_id, $meta_type . '_meta' );