Opened 6 years ago
Last modified 6 years ago
#7910 new defect (bug)
Errors being thrown from bp-groups
Reported by: | groston | Owned by: | |
---|---|---|---|
Milestone: | Awaiting Contributions | Priority: | low |
Severity: | trivial | Version: | 2.9.3 |
Component: | Groups | Keywords: | reporter-feedback |
Cc: |
Description
I found a number of error messages of the type:
PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line xxx
in the site’s debug.log file. In each case, the object that does not exist is $group and the errors occurred when a new group was being created. Though I am a true PHP/WordPress novice, to me, this feels like a bug. It seems that the routines in which these lines of code exist expect to get a group data object from the database, i.e., an existing group, but before the group is stored to the database, the object is empty.
If this notion is correct, this bug should be fixed.
Change History (4)
#2
@
6 years ago
r-a-y: My apologies, should have provided more details.
The warnings are thrown when a new group is created. I just created a group on our test site and found the following in debug.log:
[12-Jul-2018 20:00:54 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 1118 [12-Jul-2018 20:00:54 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 654 [12-Jul-2018 20:00:54 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 792 [12-Jul-2018 20:00:54 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 797 [12-Jul-2018 20:00:54 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/themes/social-portfolio/buddyboss-inc/theme-functions.php on line 1627 [12-Jul-2018 20:00:54 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 1157 [12-Jul-2018 20:00:54 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress-group-email-subscription/screen.php on line 19 [12-Jul-2018 20:00:54 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 2580 [12-Jul-2018 20:01:07 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 1118 [12-Jul-2018 20:01:07 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 654 [12-Jul-2018 20:01:07 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 792 [12-Jul-2018 20:01:07 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 797 [12-Jul-2018 20:01:07 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/themes/social-portfolio/buddyboss-inc/theme-functions.php on line 1627 [12-Jul-2018 20:01:07 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 1157 [12-Jul-2018 20:01:07 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress-group-email-subscription/screen.php on line 19 [12-Jul-2018 20:01:07 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 2580 [12-Jul-2018 20:01:14 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 1118 [12-Jul-2018 20:01:14 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 654 [12-Jul-2018 20:01:14 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 792 [12-Jul-2018 20:01:14 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 797 [12-Jul-2018 20:01:14 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/themes/social-portfolio/buddyboss-inc/theme-functions.php on line 1627 [12-Jul-2018 20:01:14 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 1157 [12-Jul-2018 20:01:14 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress-group-email-subscription/screen.php on line 19 [12-Jul-2018 20:01:14 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 2580 [12-Jul-2018 20:01:19 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 1118 [12-Jul-2018 20:01:19 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 654 [12-Jul-2018 20:01:19 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 792 [12-Jul-2018 20:01:19 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 797 [12-Jul-2018 20:01:19 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/themes/social-portfolio/buddyboss-inc/theme-functions.php on line 1627 [12-Jul-2018 20:01:19 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 1157 [12-Jul-2018 20:01:19 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress-group-email-subscription/screen.php on line 19 [12-Jul-2018 20:01:19 UTC] PHP Notice: Trying to get property of non-object in /var/www/html/wp-content/plugins/buddypress/bp-groups/bp-groups-template.php on line 2580
@groston - Thanks for the report.
It would help if you also provided the line numbers and provided us with a list of steps to duplicate so we can determine the cause of these notices.