updated cordoova-common to 1.4.0

This commit is contained in:
Steve Gill
2016-07-22 12:24:27 -07:00
parent 81e5179021
commit a5a8868d38
55 changed files with 426 additions and 279 deletions
+14 -5
View File
@@ -314,9 +314,9 @@ function SemVer(version, loose) {
else
this.prerelease = m[4].split('.').map(function(id) {
if (/^[0-9]+$/.test(id)) {
var num = +id
var num = +id;
if (num >= 0 && num < MAX_SAFE_INTEGER)
return num
return num;
}
return id;
});
@@ -966,11 +966,11 @@ function replaceXRange(comp, loose) {
} else if (gtlt === '<=') {
// <=0.7.x is actually <0.8.0, since any 0.7.x should
// pass. Similarly, <=7.x is actually <8.0.0, etc.
gtlt = '<'
gtlt = '<';
if (xm)
M = +M + 1
M = +M + 1;
else
m = +m + 1
m = +m + 1;
}
ret = gtlt + M + '.' + m + '.' + p;
@@ -1094,6 +1094,15 @@ function maxSatisfying(versions, range, loose) {
})[0] || null;
}
exports.minSatisfying = minSatisfying;
function minSatisfying(versions, range, loose) {
return versions.filter(function(version) {
return satisfies(version, range, loose);
}).sort(function(a, b) {
return compare(a, b, loose);
})[0] || null;
}
exports.validRange = validRange;
function validRange(range, loose) {
try {