Skip to content

Commit

Permalink
fix: [BUG] Agenda : can't connect Google calendar accoun - EXO-71912 (#…
Browse files Browse the repository at this point in the history
…108) (#109)

Prior to this change, using chrome to connect to google calendar account is not working anymore, this is due to that chrome is now using the dedCM (Federated Credential Management), this fix update the code by force using fcm for the prompt UI: "use_fedcm_for_prompt: true" and remove extra google.accounts.id.prompt() call that prenvent the authentication
  • Loading branch information
mkrout authored May 30, 2024
1 parent a46d8d1 commit 734b83b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ export default {
return this.authorize().then(tokenResponse => {
if (tokenResponse && tokenResponse.access_token) {
this.canPush = this.cientOauth.hasGrantedAllScopes(tokenResponse, this.SCOPE_WRITE);
this.identity.prompt();
return this.authenticate().then(() => {
return new Promise((resolve, reject) => {
if (this.credential) {
Expand Down Expand Up @@ -356,6 +355,7 @@ function initGoogleConnector(connector) {
connector.identity.initialize({
client_id: connector.CLIENT_ID,
select_by: 'user',
use_fedcm_for_prompt: true,
callback: (credResponse) => {
if (credResponse && credResponse.credential) {
const credential = jwt_decode(credResponse.credential);
Expand Down

0 comments on commit 734b83b

Please sign in to comment.