From a8dd93d28524f6674c79e0ac7286ab8afc846a40 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Sat, 2 Sep 2006 17:15:18 +0000 Subject: [PATCH] Page cap fixes from activeingredient. fixes #3096 git-svn-id: https://develop.svn.wordpress.org/trunk@4158 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/capabilities.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/capabilities.php b/wp-includes/capabilities.php index b2d2662d93..adc1827c85 100644 --- a/wp-includes/capabilities.php +++ b/wp-includes/capabilities.php @@ -324,7 +324,7 @@ function map_meta_cap($cap, $user_id) { $author_data = get_userdata($user_id); //echo "post ID: {$args[0]}
"; $page = get_page($args[0]); - $page_author_data = get_userdata($post->post_author); + $page_author_data = get_userdata($page->post_author); //echo "current user id : $user_id, page author id: " . $page_author_data->ID . "
"; // If the user is the author... if ($user_id == $page_author_data->ID) { @@ -378,7 +378,7 @@ function map_meta_cap($cap, $user_id) { $author_data = get_userdata($user_id); //echo "post ID: {$args[0]}
"; $page = get_page($args[0]); - $page_author_data = get_userdata($post->post_author); + $page_author_data = get_userdata($page->post_author); //echo "current user id : $user_id, page author id: " . $page_author_data->ID . "
"; // If the user is the author... if ($user_id == $page_author_data->ID) {