Critical Error when access Allowed Groups admin tab
-
I just installed this plugin, but when I go to the Allowed Groups tab in admin, in the first column of the table it shows this, with nothing else in the table except the first header row:
“There has been a critical error on this website. Please check your site admin email inbox for instructions. If you continue to have problems, please try the support forums.
Learn more about troubleshooting WordPress.“
The error in the email that arrives is this: An error of type E_ERROR was caused in line 33 of the file /wp-content/plugins/buddypress-groups-extras/views/admin/groups_list.php. Error message: Uncaught TypeError: in_array(): Argument #2 ($haystack) must be of type array, null given in /wp-content/plugins/buddypress-groups-extras/views/admin/groups_list.php:33
Having looked at that line, it seems that
<?php echo ( ( $bpge['groups'] === 'all' || in_array( $group_id, $bpge['groups'], true ) ) ?
is the problem. I don’t know where$bpge['groups']
is defined, but presumably in another file which is probably bpge.php.I tried commenting out
|| in_array( $group_id, $bpge['groups'], true )
which gets rid of the error but the groups are not listed, and there is just the header row. My site has 7 groups by the way. Hopefully there is a simple solution to this.
- You must be logged in to reply to this topic.