git-svn-id: https://develop.svn.wordpress.org/trunk@2225 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2005-02-05 20:45:50 +00:00
parent dc1767afe4
commit cac9401e0b
1 changed files with 6 additions and 1 deletions

View File

@ -64,7 +64,12 @@ function wp_get_single_post($postid = 0, $mode = OBJECT) {
$result = $wpdb->get_row($sql, $mode);
// Set categories
$result['post_category'] = wp_get_post_cats('',$postid);
if($mode == OBJECT) {
$result->post_category = wp_get_post_cats('',$postid);
}
else {
$result['post_category'] = wp_get_post_cats('',$postid);
}
return $result;
}