Tagged: Troubleshooting
Viewing 2 posts - 1 through 2 (of 2 total)
- AuthorPosts
- September 2, 2021 at 12:29 pm #42393
Kevin Oeste
GuestHello,
I keep getting this error:[02-Sep-2021 12:55:53 UTC] PHP Notice: Trying to get property ‘post_type’ of non-object in /home/v8tvsh5/public_html/v8speedshop.com/wp-content/themes/boldgrid-pavilion/base.php on line 16
Any ideas?
Thanks!
September 2, 2021 at 1:05 pm #42412Jesse Owens
KeymasterHi Kevin-
Thanks for the report! This error that you’re seeing from the Pavilion Theme is only a notice, and it can be safely ignored.
I’ve filed a bug report for our developers to get this fixed in the next update to Pavilion.
If you need to get these notices out of your logs, you can manually modify the
base.phpfile in thewp-content/themes/pavilion/directory. Currently, lines 15 and 16 look like this:$is_sa_invoice = 'sa_invoice' === $post->post_type; $is_sa_estimate = 'sa_estimate' === $post->post_type;
Replace those two lines with this:
if ( ! empty( $post ) ) { $is_sa_invoice = 'sa_invoice' === $post->post_type; $is_sa_estimate = 'sa_estimate' === $post->post_type; } else { $is_sa_invoice = false; $is_sa_estimate = false; } - AuthorPosts
Viewing 2 posts - 1 through 2 (of 2 total)
- The topic ‘Constant notice Trying to get property ‘post_type’ of non-object’ is closed to new replies.