V1 for the builder processing
This commit is contained in:
@@ -22,7 +22,7 @@ const tokenGenerator = (
|
||||
organization: string
|
||||
) => {
|
||||
const token = Jwt.sign(
|
||||
{ Email: Email, role: role, userId, organization: organization },
|
||||
{ Email: Email, role: role, userId: userId, organization: organization },
|
||||
jwt_secret,
|
||||
{
|
||||
expiresIn: "3h",
|
||||
@@ -37,7 +37,7 @@ const tokenRefreshGenerator = (
|
||||
organization: string
|
||||
) => {
|
||||
const token = Jwt.sign(
|
||||
{ Email: Email, role: role, userId, organization: organization },
|
||||
{ Email: Email, role: role, userId: userId, organization: organization },
|
||||
refresh_jwt_secret,
|
||||
{
|
||||
expiresIn: "30d",
|
||||
@@ -95,6 +95,7 @@ const tokenValidator = async (
|
||||
userId: string;
|
||||
organization: string;
|
||||
};
|
||||
console.log("refresh token");
|
||||
if (!decodedRefresh) {
|
||||
res.status(403).json({
|
||||
success: false,
|
||||
|
||||
Reference in New Issue
Block a user