• Resolved hamzahali

    (@hamzahali)


    Hello,
    When i am trying to login using fb login plugin it breaks (I am using http://wordpress.org/support/plugin/mycred ) plugin which gives points for login in. This is a very important feature for me.)

    Warning: Missing argument 2 for myCRED_Hook_Logging_In::logging_in() in /home2/ffj/public_html/wp-content/plugins/mycred/modules/mycred-module-hooks.php on line 413

    Warning: Cannot modify header information – headers already sent by (output started at /home2/ffj/public_html/wp-content/plugins/mycred/modules/mycred-module-hooks.php:413) in /home2/ffj/public_html/wp-includes/pluggable.php on line 876

    http://wordpress.org/extend/plugins/mycred/

Viewing 1 replies (of 1 total)
  • Plugin Author myCred

    (@designbymerovingi)

    I am assuming you are using myCRED 1.1.2.

    In the mycred/modules/mycred-module-hooks.php file on line 408 you will find the login hook. Replace the existing code with the following:

    /**
     * Login Hook
     * @since 0.1
     * @version 1.2
     */
    public function logging_in( $user_login, $user = '' ) {
    	// In case the user object is not past along
    	if ( !is_object( $user ) ) {
    		$user = get_user_by( 'login', $user_login );
    		if ( !is_object( $user ) ) return;
    	}
    	// Check for exclusion
    	if ( $this->core->exclude_user( $user->ID ) === true ) return;
    
    	// Check if we should reward
    	if ( !$this->reward_login( $user->ID ) ) return;
    
    	// Execute
    	$this->core->add_creds(
    		'logging_in',
    		$user->ID,
    		$this->prefs['creds'],
    		$this->prefs['log']
    	);
    }
Viewing 1 replies (of 1 total)
  • The topic ‘Facebook login with mycred breaking site’ is closed to new replies.