Changeset 21375
- Timestamp:
- 07/31/2012 05:39:14 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/capabilities.php
r21198 r21375 961 961 case 'delete_post': 962 962 case 'delete_page': 963 $author_data = get_userdata( $user_id );964 963 $post = get_post( $args[0] ); 965 964 … … 982 981 } else { 983 982 // No author set yet, so default to current user for cap checks. 984 $post_author_data = $author_data;983 $post_author_data = get_userdata( $user_id ); 985 984 } 986 985 … … 1011 1010 case 'edit_post': 1012 1011 case 'edit_page': 1013 $author_data = get_userdata( $user_id );1014 1012 $post = get_post( $args[0] ); 1015 1013 … … 1032 1030 } else { 1033 1031 // No author set yet, so default to current user for cap checks. 1034 $post_author_data = $author_data;1032 $post_author_data = get_userdata( $user_id ); 1035 1033 } 1036 1034 … … 1060 1058 case 'read_post': 1061 1059 case 'read_page': 1062 $author_data = get_userdata( $user_id );1063 1060 $post = get_post( $args[0] ); 1064 1061 … … 1087 1084 } else { 1088 1085 // No author set yet, so default to current user for cap checks. 1089 $post_author_data = $author_data;1086 $post_author_data = get_userdata( $user_id ); 1090 1087 } 1091 1088
Note: See TracChangeset
for help on using the changeset viewer.