fix TypeORM error "Empty criteria(s) are not allowed for the delete method."
- https://github.com/typeorm/typeorm/issues/11455 - https://github.com/typeorm/typeorm/pull/11459
This commit is contained in:
parent
23594d7373
commit
8cc3b8dd1e
11 changed files with 27 additions and 27 deletions
|
|
@ -43,7 +43,7 @@ describe('/drive/files/create', () => {
|
|||
idService = module.get(IdService);
|
||||
|
||||
const usersRepository = module.get<UsersRepository>(DI.usersRepository);
|
||||
await usersRepository.delete({});
|
||||
await usersRepository.deleteAll();
|
||||
root = await usersRepository.insert({
|
||||
id: idService.gen(),
|
||||
username: 'root',
|
||||
|
|
@ -52,7 +52,7 @@ describe('/drive/files/create', () => {
|
|||
}).then(x => usersRepository.findOneByOrFail(x.identifiers[0]));
|
||||
|
||||
const userProfilesRepository = module.get<UserProfilesRepository>(DI.userProfilesRepository);
|
||||
await userProfilesRepository.delete({});
|
||||
await userProfilesRepository.deleteAll();
|
||||
await userProfilesRepository.insert({
|
||||
userId: root.id,
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue