Property | Type | Description | |
---|---|---|---|
$module |
Method | Description | |
---|---|---|
actions ( ) | ||
connectCallback ( |
Connect social auth to the logged-in user | |
loginRegisterCallback ( |
Login/register via social auth |
Method | Description | |
---|---|---|
attemptLogin ( |
Attempt to log user in by checking if $userAuth already exists in the db, or if a user already has the email address | |
doubleCheckUsername ( |
Double checks username to ensure that it isn't already taken. If so, revert to fallback | |
initUserAuth ( |
Initialize a userAuth model based on $client data. Note that we don't set user_id yet because that can either be the currently logged in user OR a user matched by email address | |
registerAndLoginUser ( |
Register a new user using client attributes and then associate userAuth | |
setInfoFacebook ( array $attributes ) : array | Set info for facebook registration | |
setInfoGoogle ( array $attributes ) : array | Set info for google registration | |
setInfoLinkedIn ( array $attributes ) : array | Set info for LinkedIn registration | |
setInfoReddit ( array $attributes ) : array | Set info for reddit registration | |
setInfoTwitter ( array $attributes ) : array | Set info for twitter registration | |
setInfoVkontakte ( array $attributes ) : array | Set info for vkontakte registration |
protected attemptLogin ( |
||
$client | ||
return | boolean |
public connectCallback ( |
||
$client | ||
return |
protected doubleCheckUsername ( |
||
$user | ||
$fallbackUsername | string | |
return | mixed |
protected initUserAuth ( |
||
$client | ||
return | amnah\yii2\user\models\UserAuth |
public loginRegisterCallback ( |
||
$client | ||
return |
protected registerAndLoginUser ( |
||
$client | ||
$userAuth | amnah\yii2\user\models\UserAuth |
protected setInfoFacebook ( array $attributes ) : array | ||
$attributes | array | |
return | array | [$user, $profile] |
protected setInfoGoogle ( array $attributes ) : array | ||
$attributes | array | |
return | array | [$user, $profile] |
protected setInfoLinkedIn ( array $attributes ) : array | ||
$attributes | array | |
return | array | [$user, $profile] |
protected setInfoReddit ( array $attributes ) : array | ||
$attributes | array | |
return | array | [$user, $profile] |
protected setInfoTwitter ( array $attributes ) : array | ||
$attributes | array | |
return | array | [$user, $profile] |
protected setInfoVkontakte ( array $attributes ) : array | ||
$attributes | array | |
return | array | [$user, $profile] |