WordPress Reset
PHP Trying to get property of non-object Error (1 post)

  1. GKauten
    Posted 3 years ago #

    I'm not sure if this is true to all installations or just when the WP_DEBUG is enabled, but when attempting to run the plugin PHP returns the following error:

    Trying to get property of non-object on line 69

    To fix this I just modified line 69 to also look for if $user isset and modified it to treat $user as an array not an object like the code below:

    if (!isset($user) || (isset($user) && $user['user_level'] < 10) ) $user = $current_user;

    The plugin still did what it was supposed to do, it just threw that error rather than taking me to the dashboard.

    Hope this helps!


Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic


No tags yet.