Closed Nachlawi closed 4 years ago
Are there plans to add more to the API such as finding by more than id?
Maybe an option to find and findOne which accepts an object as the criteria, e.g.
this.find({ datetime: 1587036888 }, { ttl }) and this.findOne({ datetime: 1587036888 }, { ttl })
this.find({ datetime: 1587036888 }, { ttl })
this.findOne({ datetime: 1587036888 }, { ttl })
Also there are other useful methods like findOneAndUpdate?
findOneAndUpdate
No plans atm. You're welcome to contribute to #1 or #2, and I'd review a PR. Otherwise, the full Mongo API is available under this.collection.
this.collection
Are there plans to add more to the API such as finding by more than id?
Maybe an option to find and findOne which accepts an object as the criteria, e.g.
this.find({ datetime: 1587036888 }, { ttl })
andthis.findOne({ datetime: 1587036888 }, { ttl })
Also there are other useful methods like
findOneAndUpdate
?