Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating default object from empty value and Allowed memory size Fatal error #149

Open
gnanasekaranl opened this issue Apr 2, 2019 · 1 comment

Comments

@gnanasekaranl
Copy link

Following error I got,

Warning: Creating default object from empty value in /var/www/app_gic_wordpress_1/html/wp-content/plugins/wp-multi-network/wp-multi-network/includes/functions.php on line 238

Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 130968 bytes) in /var/www/app_gic_wordpress_1/html/wp-includes/class-wp-network.php on line 132

Further investigation in functions.php line number 234 overriding $current_site variable like below and this get_network( function pulling wrong data.

$current_site = get_network( $new_network );

Line 201 $current_site variable declaration as a global and overriding line number 234

global $wpdb, $switched_network, $switched_network_stack, $current_site;

If I command this line it's working properly
//$current_site = get_network( $new_network );

@JJJ
Copy link
Collaborator

JJJ commented Aug 25, 2021

Hi @gnanasekaranl 👋

Do you remember what actions you were taking to trigger this situation?

Commenting that line out will definitely break other things, so I wouldn't recommend it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants