This commit is contained in:
Tben
2023-05-23 15:25:55 +01:00
parent 1cc3d50cdc
commit 285c82193f
2 changed files with 10 additions and 2 deletions
+9 -1
View File
@@ -71,6 +71,14 @@ module.exports = async function ({ key, database, response, request, level, encr
request,
});
if (!existingUser?.payload?.id) {
return {
success: false,
payload: null,
msg: "Cookie Credentials Invalid",
};
}
/**
* Make https request
*
@@ -78,7 +86,7 @@ module.exports = async function ({ key, database, response, request, level, encr
*/
const httpResponse = await new Promise((resolve, reject) => {
const reqPayload = JSON.stringify({
existingUser,
existingUser: existingUser.payload,
database,
});