This commit is contained in:
Tben 2023-06-24 09:10:59 +01:00
parent cbda6d0c81
commit 84ca2fe08d
2 changed files with 50 additions and 52 deletions

View File

@ -52,8 +52,9 @@ module.exports = async function loginWithGoogle({ username, database, clientId,
document.body.appendChild(googleScript);
const response = await new Promise((resolve, reject) => {
googleScript.onload = function (e) {
console.log("GOOGLE script loaded!");
console.log(element);
if (google) {
if (readyStateDispatch) readyStateDispatch(true);
@ -73,7 +74,7 @@ module.exports = async function loginWithGoogle({ username, database, clientId,
gUser: null,
accessToken: response.credential,
}).then((result) => {
resolve(result);
console.log(result);
});
}
@ -107,7 +108,6 @@ module.exports = async function loginWithGoogle({ username, database, clientId,
}
}
};
});
//////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////
@ -178,6 +178,4 @@ module.exports = async function loginWithGoogle({ username, database, clientId,
//////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////
return response;
};

View File

@ -1,6 +1,6 @@
{
"name": "datasquirel",
"version": "1.1.37",
"version": "1.1.38",
"description": "Cloud-based SQL data management tool",
"main": "index.js",
"scripts": {