Remove unnecessary check.

This removed check will never be false as we pass the oplog selector that looks
for 'o.drop' and we assume that you can get only one command per oplog record.
This commit is contained in:
Slava Kim
2013-10-29 17:14:16 -07:00
committed by David Glasser
parent 008c74df4b
commit e793c9d948

View File

@@ -196,12 +196,9 @@ MongoConnection.prototype._observeChangesWithOplog = function (
var oplogEntryHandle = self._oplogHandle.onOplogEntry(
cursorDescription.collectionName, function (op) {
if (op.op === 'c') {
// If it is not db.collection.drop(), ignore it
if (op.o && _.isEqual(_.keys(op.o), ['drop'])) {
published.each(function (fields, id) {
remove(id);
});
}
published.each(function (fields, id) {
remove(id);
});
} else {
// All other operators should be handled depending on phase
oplogEntryHandlers[phase](op);