Closed KoenLav closed 3 years ago
When we use collection.:
Example:
someCollection.before.findOne(function(userId, selector) { selector = selector || {}; if (typeof selector === 'string') { selector = { _id: selector, }; } selector.someKey = 'someValue'; });
When we use findOne with a string selector the combination of someKey and someValue is ignored, when we use it with an object selector it is applied!
When we use collection.:
Example:
When we use findOne with a string selector the combination of someKey and someValue is ignored, when we use it with an object selector it is applied!