Notice fixing for wp-includes. See #5607 props filosofo.
git-svn-id: http://svn.automattic.com/wordpress/trunk@6592 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -157,12 +157,13 @@ function get_extended($post) {
|
||||
*/
|
||||
function &get_post(&$post, $output = OBJECT, $filter = 'raw') {
|
||||
global $wpdb;
|
||||
$null = null;
|
||||
|
||||
if ( empty($post) ) {
|
||||
if ( isset($GLOBALS['post']) )
|
||||
$_post = & $GLOBALS['post'];
|
||||
else
|
||||
return null;
|
||||
return $null;
|
||||
} elseif ( is_object($post) ) {
|
||||
wp_cache_add($post->ID, $post, 'posts');
|
||||
$_post = &$post;
|
||||
|
||||
Reference in New Issue
Block a user