revert: log
This commit is contained in:
parent
e4d3a66f62
commit
55ce6f831a
|
@ -107,6 +107,7 @@ export const miRepository = {
|
|||
.select('*')
|
||||
.from<ObjectLiteral>(this.metadata.tableName, this.metadata.tableName);
|
||||
builder.expressionMap.aliases.splice(1, 1);
|
||||
console.log(builder.getQueryAndParameters());
|
||||
if (findOptions) {
|
||||
return await builder.setFindOptions(findOptions).getOneOrFail();
|
||||
}
|
||||
|
|
|
@ -243,8 +243,8 @@ export function createPostgresDataSource(config: Config) {
|
|||
},
|
||||
} : false,
|
||||
logging: log,
|
||||
logger: log ? process.env.NODE_ENV === 'test' ? 'advanced-console' : new MyCustomLogger() : undefined,
|
||||
maxQueryExecutionTime: log ? 0 : 300,
|
||||
logger: log ? new MyCustomLogger() : undefined,
|
||||
maxQueryExecutionTime: 300,
|
||||
entities: entities,
|
||||
migrations: ['../../migration/*.js'],
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue