![]() ![]() Here are the possible strings that can be passed to pre()Īll middleware types support pre and post hooks. In model middleware functions, this refers to the model. Model middleware is supported for the following model functions.ĭon't confuse model middleware and document middleware: model middleware hooks into static functions on a Model class, document middleware hooks into methods on a Model class. In aggregate middleware, this refers to the aggregation object. In query middleware functions, this refers to the query.Īggregate middleware is for MyModel.aggregate().Īggregate middleware executes when you call exec() on an aggregate object. ![]() Query middleware executes when you call exec() or then() on a Query object, or await on a Query object. Query middleware is supported for the following Query functions.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |