Skip to content

Commit

Permalink
Merge pull request #48 from benediktarnold/keyf
Browse files Browse the repository at this point in the history
Add compatibility support for keyf in group command
  • Loading branch information
mafintosh committed Apr 8, 2013
2 parents 9835b78 + f4d5605 commit f0942d5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ Collection.prototype.remove = function() {
};

Collection.prototype.group = function(group, callback) {
this._apply(DRIVER_COLLECTION_PROTO.group, [group.key, group.cond, group.initial, group.reduce, group.finalize, true, callback]);
this._apply(DRIVER_COLLECTION_PROTO.group, [group.key ? group.key : group.keyf, group.cond, group.initial, group.reduce, group.finalize, true, callback]);
};

forEachMethod(DRIVER_COLLECTION_PROTO, Collection.prototype, function(methodName, fn) {
Expand Down

0 comments on commit f0942d5

Please sign in to comment.