Support » Plugin: AccessPress Social Login Lite - Social Login WordPress Plugin » Fatal Error – on login_redirect filter

  • Hi Team,

    Thanks for the awesome plugin.

    I am getting the Fatal error once, I redirect from Facebook.

    Error: Fatal error: Uncaught ArgumentCountError: Too few arguments to function

    I have added login_redirect filter in my theme to redirect users to other places.

    I digged more to find the cause about the Fatal error and I found the issue on plugin here: public_html/wp-content/plugins/accesspress-social-login-lite/inc/frontend/login_check.php Line no 705 $redirect_to = apply_filters( 'login_redirect', $redirect_to ); here need to pass 3 parameter according to WordPress filter mentioned here https://codex.wordpress.org/Plugin_API/Filter_Reference/login_redirect so I think it would be something like this $redirect_to = apply_filters( 'login_redirect', $redirect_to, $requested_redirect_to, $user );

    Can you check and provide me your thoughts please?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter Chetan Satasiya

    (@ketuchetan)

    Hey Guys,

    Is there any update on this?

    Plugin Author Access Keys

    (@access-keys)

    Hi,

    We really appreciate you writing in.

    It seems we have had the one single parameter passed to the filter hook function as you have mentioned. Can you please tell us as you added the parameters, did it resolved the issue or not. We hadn’t had the issue in our free version as we checked, so we aren’t so sure about the it. Can you please check and get back to us so we could suggest you accordingly.

    Thanks

    Thread Starter Chetan Satasiya

    (@ketuchetan)

    Hey Thanks for looking into it.

    It will sure to issues in others theme if there is only one parameter passed.

    If I make that filter like this $redirect_to = apply_filters( 'login_redirect', $redirect_to, $requested_redirect_to, $user ); into the plugin then it will resolve my issues.

    Let me know your thoughts.

    Thread Starter Chetan Satasiya

    (@ketuchetan)

    Hello @access-keys ,

    Any updates on this?

    Thanks

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Fatal Error – on login_redirect filter’ is closed to new replies.