1
0
Fork 0
mirror of https://github.com/muerwre/vk-tg-bot.git synced 2025-04-24 22:46:41 +07:00

fix typeorm ncc issue
All checks were successful
Build & Publish / Build & Publish (push) Successful in 1m28s

This commit is contained in:
Fedor Katurov 2025-02-24 21:21:19 +07:00
parent 6c064c24a0
commit bdb00e84b8

View file

@ -11,8 +11,6 @@ import { LoggerConfig } from "../../logger/types";
import { Request } from "./entities/Request";
import { Log } from "./entities/Log";
const entities = [path.join(__dirname, "./entities/*")];
export class PostgresDB implements Storage {
private connection!: Connection;
private events!: Repository<Event>;
@ -32,9 +30,9 @@ export class PostgresDB implements Storage {
this.connection = await createConnection({
type: "postgres",
url: this.config.uri,
entities,
logging: this.loggerConfig.level === "debug",
synchronize: true,
entities: [Event, Like, Post, Request, Log],
});
await this.connection.synchronize();