Cleaned up option handling for multisite

Multisite detection has been executed multiple times while the status is present in class variable after initialization.
This commit is contained in:
2018-01-07 16:17:27 +01:00
parent c2ad908481
commit 5956059327
3 changed files with 13 additions and 11 deletions

View File

@ -52,7 +52,7 @@ class StatifyBlacklist_Admin extends StatifyBlacklist {
}
// Update database on success.
if ( ( is_multisite() && array_key_exists( STATIFYBLACKLIST_BASE, (array) get_site_option( 'active_sitewide_plugins' ) ) ) ) {
if ( self::$multisite ) {
update_site_option( 'statify-blacklist', $options );
} else {
update_option( 'statify-blacklist', $options );