Update to use cap API.

git-svn-id: http://svn.automattic.com/wordpress/trunk@3095 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2005-11-16 00:50:02 +00:00
parent 0170736e28
commit 72c031e0a5
1 changed files with 1 additions and 1 deletions

View File

@ -619,7 +619,7 @@ class WP_Query {
} else {
if ('draft' == $status) {
// User must have edit permissions on the draft to preview.
if (! user_can_edit_post($user_ID, $this->posts[0]->ID)) {
if (! current_user_can('edit_post', $this->posts[0]->ID)) {
$this->posts = array();
} else {
$this->is_preview = true;