Add read_post meta cap.

git-svn-id: https://develop.svn.wordpress.org/trunk@3297 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2005-12-13 00:54:52 +00:00
parent 53271cf5ac
commit 73edfc7c20
2 changed files with 17 additions and 2 deletions

View File

@@ -643,8 +643,8 @@ class WP_Query {
} else {
$this->is_preview = true;
}
} elseif ('private' == $status) {
if ($this->posts[0]->post_author != $user_ID)
} else {
if (! current_user_can('read_post', $this->posts[0]->ID))
$this->posts = array();
}
}