Title: PHP Warning when loggin in
Last modified: March 23, 2018

---

# PHP Warning when loggin in

 *  Resolved [Debugger](https://wordpress.org/support/users/retrobeatcom/)
 * (@retrobeatcom)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/php-warning-when-loggin-in/)
 * Hi team,
    I would like to bring to Your attention a warning that is produced 
   during the login process (Facebook login in my case).
 * Bellow is the output:
 *     ```
       [Fri Mar 23 09:52:27.604862 2018] [:error] [pid 24590] [client IP:10187] PHP Warning:  Invalid argument supplied for foreach() in /var/www/SITE/wp-content/plugins/nextend-social-login-pro/class-provider-extension.php on line 75, referer: https://site.com/wp-login.php?loginSocial=facebook&code=CODE&state=STATE
       [Fri Mar 23 13:24:53.149739 2018] [:error] [pid 26060] [client ANOTHER_IP:32765] PHP Warning:  Invalid argument supplied for foreach() in /var/www/SITE/wp-content/plugins/nextend-social-login-pro/class-provider-extension.php on line 75, referer: https://site.com/wp-login.php?loginSocial=facebook&code=CODE&state=STATE
       ```
   

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Support [Gabor](https://wordpress.org/support/users/nextendweb_gabor/)
 * (@nextendweb_gabor)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/php-warning-when-loggin-in/#post-10108104)
 * Hi [@retrobeatcom](https://wordpress.org/support/users/retrobeatcom/)!
 * Please upen up that file:
    \wp-content\plugins\nextend-social-login-pro\class-
   provider-extension.php and around line 20 you can find this line:
 *     ```
       add_filter('nsl_' . $id . '_is_login_allowed', array(
           $this,
           'isLoginAllowed'
       ), 10, 2);
       ```
   
 * You should change the number 2 to 3:
 *     ```
       add_filter('nsl_' . $id . '_is_login_allowed', array(
           $this,
           'isLoginAllowed'
       ), 10, 3);
       ```
   
 * Also at line 70.:
    `public function isLoginAllowed($isAllowed, $user_id) {`
 * Add a $provider variable too:
    `public function isLoginAllowed($isAllowed, $provider,
   $user_id) {`
 * That should fix the problem and this will be in the next versions too!
 *  Thread Starter [Debugger](https://wordpress.org/support/users/retrobeatcom/)
 * (@retrobeatcom)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/php-warning-when-loggin-in/#post-10109899)
 * Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘PHP Warning when loggin in’ is closed to new replies.

 * ![](https://ps.w.org/nextend-facebook-connect/assets/icon.svg?rev=3336394)
 * [Nextend Social Login and Register](https://wordpress.org/plugins/nextend-facebook-connect/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/nextend-facebook-connect/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/nextend-facebook-connect/)
 * [Active Topics](https://wordpress.org/support/plugin/nextend-facebook-connect/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/nextend-facebook-connect/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/nextend-facebook-connect/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [Debugger](https://wordpress.org/support/users/retrobeatcom/)
 * Last activity: [8 years, 1 month ago](https://wordpress.org/support/topic/php-warning-when-loggin-in/#post-10109899)
 * Status: resolved