From 66c09d0615ece9104dd553cfa7e8004f68ef2779 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 10 Mar 2023 00:21:16 +0100 Subject: [PATCH] remove typeorm connection --- database/src/typeorm/connection.ts | 27 --------------------------- 1 file changed, 27 deletions(-) delete mode 100644 database/src/typeorm/connection.ts diff --git a/database/src/typeorm/connection.ts b/database/src/typeorm/connection.ts deleted file mode 100644 index e3434c3aa..000000000 --- a/database/src/typeorm/connection.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { createConnection, Connection } from 'typeorm' -import CONFIG from '../config' -import { entities } from '../../entity/index' - -const connection = async (): Promise => { - let con = null - try { - con = await createConnection({ - name: 'default', - type: 'mysql', - host: CONFIG.DB_HOST, - port: CONFIG.DB_PORT, - username: CONFIG.DB_USER, - password: CONFIG.DB_PASSWORD, - database: CONFIG.DB_DATABASE, - entities, - synchronize: false, - }) - } catch (error) { - // eslint-disable-next-line no-console - console.log(error) - } - - return con -} - -export default connection