Skip to content

Commit

Permalink
FIxing Mongo integration for Mongo versions 4+
Browse files Browse the repository at this point in the history
Necessary for actual Meteor version
  • Loading branch information
fknipp committed Mar 29, 2019
1 parent 05b625e commit a41ef94
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/server/db/mongo.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -96,14 +96,14 @@ module.exports = MongoDb = (options) ->
_id:
$gte: start
query._id.$lt = end if end
cursor = collection.find(query).sort('_id')
cursor = collection.find(query).sort({'_id': 1})
else
query =
'_id.doc': docName
'_id.v':
$gte: start
query['_id.v'].$lt = end if end
cursor = collection.find(query).sort('_id.v')
cursor = collection.find(query).sort({'_id.v': 1})

cursor.toArray (err, docs) ->
console.warn "failed to get ops for #{docName}: #{err}" if err
Expand Down

0 comments on commit a41ef94

Please sign in to comment.