title: Hide a specific category in admin All Posts page (Wordpress)
body: <p>Basically, when I view the All Posts page in Wordpress Admin, I want to filter out all posts (exclude them) from a specific category to not be shown there.</p>
  
  <p>After some searching, I found this hook, it works but it works in all admin</p>
  
  <pre><code>function exclude_category_posts( $query ) {
  
  if ( $query-&gt;is_main_query() &amp;&amp; is_admin()) {
      $query-&gt;set( 'cat', '-13' );
  }
  
   }
     add_filter( 'pre_get_posts', 'exclude_category_posts' );
  </code></pre>
  
  <p>I've created another menu in WP Admin that shows only posts from that excluded category but when I apply this function, it shows nothing there too. Not sure if this is possible but I thought I ask some of you kind folk here.</p>