Opened 3 years ago
Closed 3 years ago
#53135 closed defect (bug) (duplicate)
PHP Warning: Attempt to read property in class-wp-query.php
Reported by: | bwbama | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 5.7.1 |
Component: | Query | Keywords: | reporter-feedback |
Focuses: | Cc: |
Description
My error log is filled with these errors and I am having a hard time trying to figure out what might be triggering it.
[03-May-2021 01:11:31 UTC] PHP Warning: Attempt to read property "ID" on null in /home/nginx/domains/bamapolitics.com/public/wp-includes/class-wp-query.php on line 4044
[03-May-2021 01:11:31 UTC] PHP Warning: Attempt to read property "post_title" on null in /home/nginx/domains/bamapolitics.com/public/wp-includes/class-wp-query.php on line 4046
[03-May-2021 01:11:31 UTC] PHP Warning: Attempt to read property "post_name" on null in /home/nginx/domains/bamapolitics.com/public/wp-includes/class-wp-query.php on line 4048
Should there not be some checking to make sure that the property is not null?
Server is running PHP 8.0.5
Hi @bwbama,
Welcome to WordPress trac.
To debug this issue, would you be able to disable all the plugins and change to a default theme (say, Twenty Twenty One) and confirm if you still see the warning in the error log?