From 5c5363acd1f463ceecaed2e0b19517e83676843c Mon Sep 17 00:00:00 2001 From: teresagg Date: Mon, 8 Apr 2024 10:44:20 +0200 Subject: [PATCH] Trying to fix another hotspot --- .github/workflows/release.yml | 1 + gatewayservice/gateway-service.js | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index eaf4d690..f3c6e3d9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -39,6 +39,7 @@ jobs: - run: npm --prefix gatewayservice install - run: npm --prefix webapp install - run: npm --prefix webapp run build + - run: npm --prefix webapp run test:e2e docker-push-users: name: Push users Docker Image to GitHub Packages runs-on: ubuntu-latest diff --git a/gatewayservice/gateway-service.js b/gatewayservice/gateway-service.js index 3510f5dd..9b57cbd8 100644 --- a/gatewayservice/gateway-service.js +++ b/gatewayservice/gateway-service.js @@ -47,7 +47,7 @@ app.get('/user/questionsRecord/:username/:gameMode', async (req, res) => { const username = req.params.username; const gameMode = req.params.gameMode; // Forward the user statics edit request to the user service - const userResponse = await axios.get(`${userServiceUrl}/user/questionsRecord/${username}/${gameMode}`, req.body); + const userResponse = await axios.get(userServiceUrl+`/user/questionsRecord/`+username+`/`+gameMode, req.body); res.json(userResponse.data); } catch (error) { handleErrors(res, error); @@ -56,7 +56,7 @@ app.get('/user/questionsRecord/:username/:gameMode', async (req, res) => { app.post('/user/questionsRecord', async (req, res) => { try { - const response = await axios.post(`${userServiceUrl}/user/questionsRecord`, req.body); + const response = await axios.post(userServiceUrl+`/user/questionsRecord`, req.body); res.json(response.data); } catch (error) { console.error("Error al actualizar el historial de preguntas:", error); @@ -99,7 +99,7 @@ app.get('/user/get/:username', async (req, res) => { try { const username = req.params.username; // Forward the user statics edit request to the user service - const userResponse = await axios.get(`${userServiceUrl}/user/get/${username}`, req.body); + const userResponse = await axios.get(userServiceUrl+'/user/get/'+username, req.body); res.json(userResponse.data); } catch (error) { handleErrors(res, error);