From 3e076ba536dbc91ec05719df8713b0af1d5a0d40 Mon Sep 17 00:00:00 2001 From: ryan Date: Sat, 2 Sep 2006 17:15:18 +0000 Subject: [PATCH] Page cap fixes from activeingredient. fixes #3096 git-svn-id: http://svn.automattic.com/wordpress/trunk@4158 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- 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 b2d2662d9..adc1827c8 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) {