Commit c4b643ca authored by Cyrille37's avatar Cyrille37

unique installer instance

parent 8685f048
...@@ -23,9 +23,10 @@ class CommunityVoice ...@@ -23,9 +23,10 @@ class CommunityVoice
add_action( 'activated_plugin', array( $this, 'load_plugin_first' ) ); add_action( 'activated_plugin', array( $this, 'load_plugin_first' ) );
register_activation_hook( __FILE__, array( new CommunityVoice_install(), 'activate' ) ); $installer = new CommunityVoice_install() ;
register_deactivation_hook( __FILE__, array( new CommunityVoice_install(), 'deactivate' ) ); register_activation_hook( __FILE__, array( $installer, 'activate' ) );
register_uninstall_hook( __FILE__, array( 'CommunityVoice_install', 'uninstall' ) ); register_deactivation_hook( __FILE__, array( $installer, 'deactivate' ) );
register_uninstall_hook( __FILE__, array( $installer, 'uninstall' ) );
add_action( 'wp_enqueue_scripts', array( $this, 'load_script' ) ); add_action( 'wp_enqueue_scripts', array( $this, 'load_script' ) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment