mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-07-01 15:50:09 +00:00
Even better, remove all UI for global terms. Add a filter to global_terms_enabled() and also allow the site option to simply be deleted. fixes #12666.
git-svn-id: https://develop.svn.wordpress.org/trunk@14854 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -3829,7 +3829,7 @@ function is_main_site( $blog_id = '' ) {
|
||||
}
|
||||
|
||||
/**
|
||||
* are global terms enabled
|
||||
* Whether global terms are enabled.
|
||||
*
|
||||
*
|
||||
* @since 3.0.0
|
||||
@@ -3842,8 +3842,13 @@ function global_terms_enabled() {
|
||||
return false;
|
||||
|
||||
static $global_terms = null;
|
||||
if ( is_null( $global_terms ) )
|
||||
$global_terms = (bool) get_site_option( 'global_terms_enabled' );
|
||||
if ( is_null( $global_terms ) ) {
|
||||
$filter = apply_filters( 'global_terms_enabled', null );
|
||||
if ( ! is_null( $filter ) )
|
||||
$global_terms = (bool) $filter;
|
||||
else
|
||||
$global_terms = (bool) get_site_option( 'global_terms_enabled', false );
|
||||
}
|
||||
return $global_terms;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user