diff --git a/rce-server/server/api/middlewares/isLogged.handler.js b/rce-server/server/api/middlewares/isLogged.handler.js index bf7b53b..85bb5ec 100644 --- a/rce-server/server/api/middlewares/isLogged.handler.js +++ b/rce-server/server/api/middlewares/isLogged.handler.js @@ -1,7 +1,7 @@ import jwt from "jsonwebtoken"; import mongoose from "mongoose"; import User from "../../models/user"; -const JWT_SECRET = "abcd"; +const JWT_SECRET = process.env.JWT_SECRET; module.exports = (req, res, next) => { try { diff --git a/rce-server/server/api/services/auth.service.js b/rce-server/server/api/services/auth.service.js index 52918ae..fff96c5 100644 --- a/rce-server/server/api/services/auth.service.js +++ b/rce-server/server/api/services/auth.service.js @@ -1,7 +1,7 @@ import jwt from "jsonwebtoken"; import mongoose from "mongoose"; const User = require("../../models/user"); -const JWT_SECRET = "abcd"; +const JWT_SECRET = process.env.JWT_SECRET; class AuthService { async execute(email, name, dp) { diff --git a/rce-server/server/api/services/link.service.js b/rce-server/server/api/services/link.service.js index 368ee44..a06b4b9 100644 --- a/rce-server/server/api/services/link.service.js +++ b/rce-server/server/api/services/link.service.js @@ -1,7 +1,7 @@ import mongoose from "mongoose"; import crypto from "crypto"; const Link = require("../../models/link"); -const BASE_URI = "http://localhost:3000/"; +const BASE_URI = process.env.BASE_URI; class LinkService { async generate(user) {