Skip to content

Commit

Permalink
Setup default WP settings on plugin activation
Browse files Browse the repository at this point in the history
  • Loading branch information
julien731 committed Mar 4, 2016
1 parent fb34688 commit 1a45d6d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion better-optin.php
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,6 @@ private function includes() {
require( WPBO_PATH . 'includes/shortcode.php' );
require( WPBO_PATH . 'includes/functions-templating.php' );
require( WPBO_PATH . 'includes/functions-dummy.php' );
require( WPBO_PATH . 'includes/install.php' );

}

Expand Down Expand Up @@ -268,6 +267,7 @@ private function includes_admin() {
require( WPBO_PATH . 'includes/admin/functions-menu.php' );
require( WPBO_PATH . 'includes/admin/functions-metabox.php' );
require( WPBO_PATH . 'includes/admin/functions-list-table.php' );
require( WPBO_PATH . 'includes/install.php' );
}

}
Expand Down
6 changes: 5 additions & 1 deletion includes/providers/wordpress/load.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@
die;
}

if ( 'word-press' === wpbo_get_option( 'mailing_provider', '' ) ) {
// Get the current provider
$provider = wpbo_get_option( 'mailing_provider', '' );

// Default to WP provider settings if no provider is set (used during install)
if ( 'word-press' === $provider || empty( $provider ) ) {

// Load provider files
require( WPBO_PATH . 'includes/providers/wordpress/settings.php' );
Expand Down

0 comments on commit 1a45d6d

Please sign in to comment.