Skip to content

Commit cf768dc

Browse files
fix: add clarifying comment
1 parent c2caa0f commit cf768dc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/helpers/model/applyStaticHooks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ module.exports = function applyStaticHooks(model, hooks, statics) {
1515
};
1616

1717
hooks = hooks.filter(hook => {
18-
// If the custom static overwrites an existing middleware, don't apply
18+
// If the custom static overwrites an existing query/aggregate middleware, don't apply
1919
// middleware to it by default. This avoids a potential backwards breaking
2020
// change with plugins like `mongoose-delete` that use statics to overwrite
2121
// built-in Mongoose functions.

0 commit comments

Comments
 (0)