Trying to get property of non-object
-
After receiving a non-wp payment, got the log filled with about 30 entries like these:
PHP Notice: Trying to get property of non-object in plugins/paypal-ipn/admin/class-paypal-ipn-for-wordpress-admin.php on line 164
Lines 163-164:
global $current_screen; if( $current_screen->post_type == 'paypal_ipn' ) {
According this post with a similar issue,
$current_screen
should be called like this instead:$current_screen = get_current_screen(); if( $current_screen->post_type == 'paypal_ipn' ) {
Thanks.
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Trying to get property of non-object’ is closed to new replies.