Skip to content

Commit f450083

Browse files
committed
docs(migrating_to_8): add note about removing findByIdAndRemove
Fix #15024
1 parent 445a76d commit f450083

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

docs/migrating_to_8.md

+3
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,9 @@ In Mongoose 7, `findOneAndRemove()` was an alias for `findOneAndDelete()` that M
8787
Mongoose 8 no longer supports `findOneAndRemove()`.
8888
Use `findOneAndDelete()` instead.
8989

90+
Similarly, Mongoose 8 no longer supports `findByIdAndRemove()`, which was an alias for `findByIdAndDelete()`.
91+
Please use `findByIdAndDelete()` instead.
92+
9093
## Removed `count()` {#removed-count}
9194

9295
`Model.count()` and `Query.prototype.count()` were removed in Mongoose 8. Use `Model.countDocuments()` and `Query.prototype.countDocuments()` instead.

0 commit comments

Comments
 (0)