fix(backend): fake where

This commit is contained in:
Acid Chicken (硫酸鶏) 2024-05-29 15:47:52 +09:00
parent f8851e6d51
commit 86dd737def
No known key found for this signature in database
GPG Key ID: 3E87B98A3F6BAB99
1 changed files with 2 additions and 1 deletions

View File

@ -100,7 +100,8 @@ export const miRepository = {
const builder = this.createQueryBuilder()
.addCommonTableExpression(queryBuilder, this.metadata.tableName, { columnNames })
.select('*')
.from<ObjectLiteral>(this.metadata.tableName, this.metadata.tableName);
.from<ObjectLiteral>(this.metadata.tableName, this.metadata.tableName)
.where('1 = 1');
if (findOptions) {
return await builder.setFindOptions(findOptions).getOneOrFail();
}