Plugin Author
AITpro
(@aitpro)
Wierd. BPS does not use the wp_get_current_user() function. BPS does use the WordPress current_user_can() function to check user capabilities.
Try commenting out the line you added below with 2 forward slashes and let me know if the error occurs again. It may have just been a coincidence or maybe there is some other factor that is not obvious going on.
// require_once(ABSPATH . ‘wp-includes/pluggable.php’);
Plugin Author
AITpro
(@aitpro)
Did you Network Activate BPS on your Network/Multisite installation? BPS should not be Network Activated and should only be activated on the Primary site for Network/Multisite.
Plugin Author
AITpro
(@aitpro)
Oops yeah wp_get_current_user() is in capabilities and not BPS. Spaced out for a sec. LOL. Apparently this is some odd random occurrence that happens only on Mulitsite and I do not see that anyone has ever figured out what actually causes it. I will add this as it would not hurt anything, but I will need to research it fully before adding it. Thanks.
Plugin Author
AITpro
(@aitpro)
This has been researched and tested and everything works perfectly. Thank you for pointing this out. Very much appreciated.
Thread Starter
Eddie
(@eddie6671)
It was my pleasure, and many thanks for being so responsive, and for your work on this excellent plugin 🙂
Look forward to the fix appearing soon, but if it doesn’t, no big deal, I have my ugly kludge patch. Here it is in case it helps any multisite people until the real fix is merged:
--- a/wp-content/plugins/bulletproof-security/bulletproof-security.php 2013-04-17 23:11:09.640004664 +0100
+++ b/wp-content/plugins/bulletproof-security/bulletproof-security.php 2013-04-17 23:10:30.610004665 +0100
@@ -46,6 +46,7 @@
// If in WP Admin Dashboard
if ( is_admin() ) {
+ require_once(ABSPATH . 'wp-includes/pluggable.php');
require_once( WP_PLUGIN_DIR . '/bulletproof-security/admin/includes/admin.php' );
register_activation_hook(__FILE__, 'bulletproof_security_install');
register_deactivation_hook(__FILE__, 'bulletproof_security_deactivation');
Plugin Author
AITpro
(@aitpro)
adding just…
require_once(ABSPATH . 'wp-includes/pluggable.php');
…causes some problems for other plugins so this code will be changed to include this additional conditional check below…
if ( is_admin() ) {
require_once( WP_PLUGIN_DIR . '/bulletproof-security/admin/includes/admin.php' );
if ( wp_script_is( 'bps-js', $list = 'queue' ) ) {
require_once(ABSPATH . 'wp-includes/pluggable.php');
}
Please test this code on your site and let me know if it works. Thanks.
Plugin Author
AITpro
(@aitpro)
Wow dumb one. Went down the rabbit hole looking in the wrong place. This is the correct solution to the problem.
http://ww.wp.xz.cn/support/topic/36-beta-issue?replies=3