UNPKG

542 BJavaScriptView Raw
1'use strict';
2
3/*!
4 * ignore
5 */
6
7const queryOperations = Object.freeze([
8 // Read
9 'countDocuments',
10 'distinct',
11 'estimatedDocumentCount',
12 'find',
13 'findOne',
14 // Update
15 'findOneAndReplace',
16 'findOneAndUpdate',
17 'replaceOne',
18 'updateMany',
19 'updateOne',
20 // Delete
21 'deleteMany',
22 'deleteOne',
23 'findOneAndDelete'
24]);
25
26exports.queryOperations = queryOperations;
27
28/*!
29 * ignore
30 */
31
32const queryMiddlewareFunctions = queryOperations.concat([
33 'validate'
34]);
35
36exports.queryMiddlewareFunctions = queryMiddlewareFunctions;