test
This commit is contained in:
@@ -303,11 +303,11 @@ class Wiaas_Document {
|
||||
return;
|
||||
}
|
||||
|
||||
foreach (self::$available_doc_types as $key => $available_doc_type) {
|
||||
wp_insert_term($available_doc_type['name'], 'wpdmcategory', array(
|
||||
'slug' => $key
|
||||
));
|
||||
}
|
||||
// foreach (self::$available_doc_types as $key => $available_doc_type) {
|
||||
// wp_insert_term($available_doc_type['name'], 'wpdmcategory', array(
|
||||
// 'slug' => $key
|
||||
// ));
|
||||
// }
|
||||
}
|
||||
|
||||
public static function register_wiaas_document() {
|
||||
@@ -400,11 +400,11 @@ class Wiaas_Document {
|
||||
register_taxonomy( 'wiaas_doc_type', array( 'wiaas_doc' ), $args );
|
||||
|
||||
foreach (self::$available_doc_types as $key => $available_doc_type) {
|
||||
if (! has_term($available_doc_type['name'], 'wiaas_doc_type')) {
|
||||
wp_insert_term($available_doc_type['name'], 'wiaas_doc_type', array(
|
||||
'slug' => $key
|
||||
));
|
||||
}
|
||||
// if (! has_term($available_doc_type['name'], 'wiaas_doc_type')) {
|
||||
// wp_insert_term($available_doc_type['name'], 'wiaas_doc_type', array(
|
||||
// 'slug' => $key
|
||||
// ));
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user