mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-12 12:50:28 +00:00
Bit twiddling. Add type bitfield to categories table. see #3723
git-svn-id: https://develop.svn.wordpress.org/trunk@5184 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
<?php
|
||||
|
||||
define('TAXONOMY_CATEGORY', 1);
|
||||
define('TAXONOMY_TAG', 2);
|
||||
|
||||
function get_all_category_ids() {
|
||||
global $wpdb;
|
||||
|
||||
@@ -78,7 +81,7 @@ function &get_categories($args = '') {
|
||||
else
|
||||
$where .= ' AND category_count > 0';
|
||||
} else {
|
||||
$where .= ' AND ( tag_count = 0 OR ( tag_count != 0 AND ( link_count > 0 OR category_count > 0 ) ) ) ';
|
||||
$where .= ' AND ( type & ' . TAXONOMY_CATEGORY . ' != 0 ) ';
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user