Home Forums Newsletter Plugin Support PHP Fatal Error When Subscriber Saves His Profile Edit

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #323060
    nicolas
    Participant

    This error is thrown. Posting here to report.

    PHP Fatal error: Uncaught Error: Call to a member function get_error_message() on string in /home/site/wp-content/plugins/newsletter/profile/profile.php:98

    The error stems from this instruction on line 98$this->redirect($this->message_url($user, $email, $res->get_error_message()));

    I’ve patched it by removing the

    ->get_error_message()

    part. if

    $res

    is not an WP_Error object, then it wont contain the

    get_error_message()

    method.

    Might also be good to add a

    break;

    after line 95, within the if statement. Not sure how the

    redirect()

    method works but if

    $res

    is an WP_Error object, there is no need to go further in the switch statement.

    #323062
    Stefano
    Keymaster

    Arghhh! That version shouldn’t have been distributed, it was an error on the 8.2.2 package suddenly replaced… but of course, it was not. See the 8.2.3, it’s just a republishing of the correct package with a new version number, to be sure the correct code is distributed.

    Thank you very much for reporting!

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.