I just wanted to add this as a SOLVED question because it took me a while to figure it out and there was no documentation on this.
Notice: Trying to get property of non-object in /srv/www/wordpress-default/wp-includes/post.php on line 3555
Trying to wp_update_post() via plugin settings page and was getting this notice.
The solution was to add this line before calling the wp function: $wp_rewrite = new wp_rewrite;
The solution was to add this line before calling the WP function: $wp_rewrite = new wp_rewrite;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With