Created setup environment
This commit is contained in:
@ -19,10 +19,7 @@ use Bdp\Modules\Seo\Seo;
|
||||
require_once dirname(__FILE__) . '/includes/setup.php';
|
||||
|
||||
function bdp_plugin_install() {
|
||||
Seo::setup();
|
||||
Calendar::setup();
|
||||
Security::setup();
|
||||
update_option('kompass_installation', true);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -30,11 +27,14 @@ function bdp_plugin_init() {
|
||||
Security::ProhibitBots();
|
||||
Security::SetPageFilters();
|
||||
|
||||
remove_menu_page( 'admin.php?page=limit-login-attempts&tab=dashboard' );
|
||||
if ( get_option( 'kompass_installation' ) == true ) {
|
||||
delete_option( 'kompass_installation' );
|
||||
if (null == get_option('kompass_already_installed', null)) {
|
||||
Seo::setup();
|
||||
Calendar::setup();
|
||||
Security::setup();
|
||||
update_option('kompass_already_installed', true);
|
||||
wp_redirect( 'site-health.php?tab=bdp_enhanced_security');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
add_action('admin_menu', function () {
|
||||
|
Reference in New Issue
Block a user