mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 21:22:58 +01:00
Connected Gmail Account
This commit is contained in:
parent
cfef367952
commit
0c5b551ce1
@ -97,21 +97,12 @@ class ConnectedAccountController extends BaseController
|
|||||||
$client->setClientId(config('ninja.auth.google.client_id'));
|
$client->setClientId(config('ninja.auth.google.client_id'));
|
||||||
$client->setClientSecret(config('ninja.auth.google.client_secret'));
|
$client->setClientSecret(config('ninja.auth.google.client_secret'));
|
||||||
$client->setRedirectUri(config('ninja.app_url'));
|
$client->setRedirectUri(config('ninja.app_url'));
|
||||||
// $token = $client->authenticate(request()->input('server_auth_code'));
|
|
||||||
|
|
||||||
$refresh_token = '';
|
$refresh_token = '';
|
||||||
|
|
||||||
// if (array_key_exists('refresh_token', $token)) {
|
|
||||||
// $refresh_token = $token['refresh_token'];
|
|
||||||
// }
|
|
||||||
|
|
||||||
$token = '';
|
$token = '';
|
||||||
|
|
||||||
$connected_account = [
|
$connected_account = [
|
||||||
'email' => $google->harvestEmail($user),
|
'email' => $google->harvestEmail($user),
|
||||||
'oauth_user_id' => $google->harvestSubField($user),
|
'oauth_user_id' => $google->harvestSubField($user),
|
||||||
// 'oauth_user_token' => $token,
|
|
||||||
// 'oauth_user_refresh_token' => $refresh_token,
|
|
||||||
'oauth_provider_id' => 'google',
|
'oauth_provider_id' => 'google',
|
||||||
'email_verified_at' =>now()
|
'email_verified_at' =>now()
|
||||||
];
|
];
|
||||||
@ -153,8 +144,6 @@ class ConnectedAccountController extends BaseController
|
|||||||
$refresh_token = $token['refresh_token'];
|
$refresh_token = $token['refresh_token'];
|
||||||
}
|
}
|
||||||
|
|
||||||
$token = '';
|
|
||||||
|
|
||||||
$connected_account = [
|
$connected_account = [
|
||||||
'email' => $google->harvestEmail($user),
|
'email' => $google->harvestEmail($user),
|
||||||
'oauth_user_id' => $google->harvestSubField($user),
|
'oauth_user_id' => $google->harvestSubField($user),
|
||||||
|
Loading…
Reference in New Issue
Block a user