MongoUtils Addons and utility methods for dealing with mongo - stuff that FanLink doesn't do
Do an atomic increment/decrement on a field It's a bit of a hack, but we can't simply use a fanlink object since we would have to have a
$incnamed field, which is an illegal field name ... so just building that by hand.
Note that incBy can be negative for doing an atomic decrease.
Just syntax sugar for manually creating mongo docs
Using same naming convention as fanlink
Most recenty updated public pods Because we bypass fanlink we get a plain list as the result
remove an item from the db
Take a standard fan query and build a mongo query object from it This should be much faster than fetching all and filtering locally as done by query.include
right now it's not very optimized, much of the filtering is done here rather tha building the exact mongo query to get what we need ... but that's would be lots of work and version would be tricky.
Search pod names and summary (can use patterns) Because we bypass fanlink we get a plain list as the result
Most downloaded public pods Because we bypass fanlink we get a plain list as the result