• I have Photo Gallery Version 1.8.42 installed, which I believe is the latest version. I am seeing PHP Warnings like this in a log file:

    [07-Aug-2026 03:32:03 UTC] PHP Warning:  Undefined property: stdClass::$user_email in /var/www/sites/XXXXX/wp-content/plugins/photo-gallery/wd/includes/deactivate.php on line 69

    [07-Aug-2026 07:10:44 UTC] PHP Warning:  Undefined property: stdClass::$user_email in /var/www/sites/XXXXX/wp-content/plugins/photo-gallery/wd/includes/deactivate.php on line 69

Viewing 1 replies (of 1 total)
  • Thread Starter babola

    (@babola)

    Regarding the problem on line 69 of deactivate.php…

    "email" => $admin_data->data->user_email,

    .… the scripts() function is enqueued on admin pages and wp_get_current_user() returns a bare stdClass with no user_email when no user is logged in. The fix is a simple null coalescing guard:

    "email" => $admin_data->data->user_email ?? "",

    • This reply was modified 4 days, 3 hours ago by babola.
Viewing 1 replies (of 1 total)

You must be logged in to reply to this topic.