Ensure _.sortBy performs a stable sort. [closes #59]

Former-commit-id: 09c5ff85ef0f1d054579ec4260a7f76d9c0da281
This commit is contained in:
John-David Dalton
2012-08-16 23:24:59 -07:00
parent 83d08e3aba
commit fab2d69fce
3 changed files with 36 additions and 6 deletions

View File

@@ -151,6 +151,7 @@
'head',
'identity',
'include',
'index',
'indexOf',
'initial',
'inject',
@@ -304,7 +305,7 @@
// minify internal properties used by 'compareAscending', `_.clone`, `_.merge`, and `_.sortBy`
(function() {
var properties = ['criteria', 'source', 'value'],
var properties = ['criteria', 'index', 'source', 'value'],
snippets = source.match(/( +)(?:function clone|function compareAscending|var merge|var sortBy)\b[\s\S]+?\n\1}/g);
if (!snippets) {