added views and Authclients
This commit is contained in:
25
lib/User/AuthClient/Google.php
Normal file
25
lib/User/AuthClient/Google.php
Normal file
@ -0,0 +1,25 @@
|
||||
<?php
|
||||
namespace Da\User\AuthClient;
|
||||
|
||||
use Da\User\Contracts\AuthClientInterface;
|
||||
|
||||
class Google extends \yii\authclient\clients\Google implements AuthClientInterface
|
||||
{
|
||||
/**
|
||||
* @inheritdoc
|
||||
*/
|
||||
public function getEmail()
|
||||
{
|
||||
return isset($this->getUserAttributes()['emails'][0]['value'])
|
||||
? $this->getUserAttributes()['emails'][0]['value']
|
||||
: null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @inheritdoc
|
||||
*/
|
||||
public function getUsername()
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user