From c92ec668aa5de7c38720158afcc244a926396b2f Mon Sep 17 00:00:00 2001 From: Thomas Chazot Date: Thu, 14 Dec 2023 08:44:04 +0100 Subject: [PATCH] fix --- cryptide_project/server/api/services/DatabaseService.js | 4 ++-- cryptide_project/src/AdressSetup.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cryptide_project/server/api/services/DatabaseService.js b/cryptide_project/server/api/services/DatabaseService.js index 1be7fd2..47bf881 100644 --- a/cryptide_project/server/api/services/DatabaseService.js +++ b/cryptide_project/server/api/services/DatabaseService.js @@ -33,7 +33,7 @@ class DatabaseService { reject(err); } else { if (createTables === "true"){ - this.createTables() + await this.createTables() console.log("create table") } @@ -42,7 +42,7 @@ class DatabaseService { const showTablesQuery = 'SHOW TABLES'; // Execute the query - const [rows, fields] = await connection.promise().query(showTablesQuery); + const [rows, fields] = await this.client.promise().query(showTablesQuery); // Extract table names from the result const tableNames = rows.map(row => row[`Tables_in_${dbConfig.database}`]); diff --git a/cryptide_project/src/AdressSetup.ts b/cryptide_project/src/AdressSetup.ts index 51ee072..231524c 100644 --- a/cryptide_project/src/AdressSetup.ts +++ b/cryptide_project/src/AdressSetup.ts @@ -8,7 +8,7 @@ const tmp2 = ADRESSE_WEBSERVER const ADRESSE_WEBSITE = "" -const basePath = process.env.REACT_APP_BASEPATH || ''; +const basePath = process.env.REACT_APP_BASEPATH || 'containers/Crypteam-website'; console.log(basePath)