diff options
Diffstat (limited to 'vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/internal/compareAscending.js')
-rw-r--r-- | vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/internal/compareAscending.js | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/internal/compareAscending.js b/vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/internal/compareAscending.js new file mode 100644 index 00000000..f17b1175 --- /dev/null +++ b/vnfmarket/src/main/webapp/vnfmarket/node_modules/lodash/internal/compareAscending.js @@ -0,0 +1,16 @@ +var baseCompareAscending = require('./baseCompareAscending'); + +/** + * Used by `_.sortBy` to compare transformed elements of a collection and stable + * sort them in ascending order. + * + * @private + * @param {Object} object The object to compare. + * @param {Object} other The other object to compare. + * @returns {number} Returns the sort order indicator for `object`. + */ +function compareAscending(object, other) { + return baseCompareAscending(object.criteria, other.criteria) || (object.index - other.index); +} + +module.exports = compareAscending; |