From d1a9adb98083995ad49c81eccb2872daa12a7226 Mon Sep 17 00:00:00 2001 From: Matt Mullenweg Date: Wed, 5 Mar 2008 18:49:56 +0000 Subject: [PATCH] Don't return early before filtering. git-svn-id: https://develop.svn.wordpress.org/trunk@7161 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/post.php | 4 ---- 1 file changed, 4 deletions(-) diff --git a/wp-includes/post.php b/wp-includes/post.php index 5b556620a9..a14c1e56fd 100644 --- a/wp-includes/post.php +++ b/wp-includes/post.php @@ -725,13 +725,9 @@ function sanitize_post($post, $context = 'display') { if ( 'raw' == $context ) return $post; if ( is_object($post) ) { - if ( !isset($post->ID) ) - return $post; foreach ( array_keys(get_object_vars($post)) as $field ) $post->$field = sanitize_post_field($field, $post->$field, $post->ID, $context); } else { - if ( !isset($post['ID']) ) - return $post; foreach ( array_keys($post) as $field ) $post[$field] = sanitize_post_field($field, $post[$field], $post['ID'], $context); }