Skip to content

Commit

Permalink
plugin activate load order
Browse files Browse the repository at this point in the history
Signed-off-by:KProvance <kevin.provance@gmail.com>
  • Loading branch information
kprovance committed Apr 28, 2015
1 parent 889b537 commit 63501fa
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion class.redux-plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,12 @@ private function hooks() {
}

public function load_first() {
$path = str_replace( WP_PLUGIN_DIR . '/', '', __FILE__ );
$plugin_dir = Redux_Helpers::cleanFilePath(WP_PLUGIN_DIR) . '/';
$self_file = Redux_Helpers::cleanFilePath( __FILE__ );

$path = str_replace( $plugin_dir , '', $self_file );
$path = str_replace('class.redux-plugin.php', 'redux-framework.php', $path);

if ( $plugins = get_option( 'active_plugins' ) ) {
if ( $key = array_search( $path, $plugins ) ) {
array_splice( $plugins, $key, 1 );
Expand Down

0 comments on commit 63501fa

Please sign in to comment.