Hide Pages on Edit Pages based on Capability (edit_others_pages)?
I was using the wrong query_var. It’s author not post_author. add_action( ‘pre_get_posts’, ‘wps_admin_exclude_pages’ ); function wps_admin_exclude_pages( $query ) { if( ! is_admin() ) return $query; global $pagenow, $user_ID; if( ‘edit.php’ == $pagenow && ‘page’ == get_query_var( ‘post_type’ ) && ! current_user_can( ‘edit_others_pages’ ) ) $query->set( ‘author’, $user_ID ); return $query; }