Skip to content
This repository was archived by the owner on Mar 18, 2022. It is now read-only.

Commit 587d534

Browse files
thomasgielingpleerock
authored andcommitted
use remove in stead of delete (typeorm#4574)
the `remove` method requires the entity itself as input. To remove a record based on it's id, you need to use `delete`
1 parent a925be9 commit 587d534

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

docs/example-with-express.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ createConnection().then(connection => {
233233
});
234234

235235
app.delete("/users/:id", async function(req: Request, res: Response) {
236-
const results = await userRepository.remove(req.params.id);
236+
const results = await userRepository.delete(req.params.id);
237237
return res.send(results);
238238
});
239239

0 commit comments

Comments
 (0)