WordPress.org

Make WordPress Core

Ticket #22448: 22448.diff

File 22448.diff, 483 bytes (added by kovshenin, 6 years ago)
  • wp-includes/post.php

     
    581581                        wp_cache_add( $_post->ID, $_post, 'posts' );
    582582                }
    583583
     584                // Sanitize the post if it has not been satized.
     585                if ( empty( $_post->filter ) ) {
     586                        $_post = sanitize_post( $_post, 'raw' );
     587                        wp_cache_set( $_post->ID, $_post, 'posts' );
     588                }
     589
    584590                return new WP_Post( $_post );
    585591        }
    586592