• Resolved joneiseman

    (@joneiseman)


    I’m getting a lot of PHP Notices like this:

    PHP Notice: Undefined index: f7a28b2793a158e59e3e6bee8e6c9ce92ec339fee09be0541f566f00a6b0bcf4 in /home/.../public_html/wp-content/plugins/wp-persistent-login/classes/wp-persistent-login.php on line 422

    Any way to fix this?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author lukeseager

    (@lukeseager)

    Hi @joneiseman,

    Are you able to provide the details below please?

    • Which version of Persistent Login you’re using?
    • What version of PHP are you running?
    Thread Starter joneiseman

    (@joneiseman)

    I was using 2.0.11 and now I’m using 2.0.12. PHP version 7.4. To fix the notices I modified classes/wp-persistent-login.php on line 421 to verify the indices exist. So, now I’m not seeing the notices.

                        // if we're on the same user agent and same IP, we're probably on the same device
                        // delete the duplicate session
                        if( array_key_exists( $verifier, $sessions ) &&
                            array_key_exists( 'ip', $sessions[$verifier] ) &&
                            array_key_exists( 'ua', $sessions[$verifier] ) &&
                            ($session['ip'] === $sessions[$verifier]['ip']) &&
                            ($session['ua'] === $sessions[$verifier]['ua'])
                        ) :
    
    Plugin Author lukeseager

    (@lukeseager)

    hi @joneiseman,

    Ah I see, thank you for this. I will add a fix in the next release to avoid the issue going forward.

    Thanks, Luke

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘PHP Notices from classes/wp-persistent-login.php’ is closed to new replies.