WordPress.org

Make WordPress Core

Ticket #15483: 15483.diff

File 15483.diff, 543 bytes (added by scribu, 3 years ago)
  • wp-includes/post.php

     
    14901490 * @return array 
    14911491 */ 
    14921492function get_post_custom( $post_id = 0 ) { 
    1493         $post_id = absint( $post_id ); 
    1494  
    1495         if ( ! $post_id ) 
    1496                 $post_id = get_the_ID(); 
    1497  
    1498         if ( ! wp_cache_get( $post_id, 'post_meta' ) ) 
    1499                 update_postmeta_cache( $post_id ); 
    1500  
    1501         return wp_cache_get( $post_id, 'post_meta' ); 
     1493        return get_metadata( 'post', $post_id ); 
    15021494} 
    15031495 
    15041496/**