browser-update
Advanced tools
Comparing version 2.1.0 to 2.1.1
{ | ||
"name": "browser-update", | ||
"version": "2.1.0", | ||
"version": "2.1.1", | ||
"description": "Remind users to update their browser in an unobtrusive way.", | ||
@@ -5,0 +5,0 @@ "main": "update.npm.full.js", |
@@ -37,3 +37,3 @@ //(c)2017, MIT Style License <browser-update.org/LICENSE.txt> | ||
for (var i=0; i < pats.length; i++) { | ||
if (ua.match(new RegExp(pats[i][0].replace("VV","(\\d+\\.?\\d?)"),"i"))) { | ||
if (ua.match(new RegExp(pats[i][0].replace("VV","(\\d+\\.?\\d+)"),"i"))) { | ||
n=pats[i][1]; | ||
@@ -43,8 +43,10 @@ break; | ||
} | ||
if (n==="v"||n==="y") {//zero pad semver for easy comparing | ||
var semver=n==="v"||n==="y"; | ||
if (semver) {//zero pad semver for easy comparing | ||
var parts = (RegExp.$1).split('.'); | ||
var v=parseFloat(parts[0] + "." + ("00".substring(0, 2 - parts[1].length) + parts[1])); | ||
var v=(parts[0] + "." + ("00".substring(0, 2 - parts[1].length) + parts[1])); | ||
} | ||
else | ||
var v=parseFloat(RegExp.$1); | ||
else { | ||
var v=Math.round(parseFloat(RegExp.$1)*10)/10; | ||
} | ||
@@ -111,3 +113,3 @@ if (!n) | ||
var vsakt = {i:12,f:53,o:44,s:10.1,n:20,c:58,y:17.04,v:1.10}; | ||
var vsdefault = {i:-2,f:-4,o:-4,s:-1.7,n:12,c:-4,a:534,y:-0.2,v:-0.2}; | ||
var vsdefault = {i:-2,f:-4,o:-4,s:-1.7,n:12,c:-4,a:534,y:-0.02,v:-0.02}; | ||
if (op.apiver<4) | ||
@@ -114,0 +116,0 @@ vsmin={i:9,f:10,o:20,s:7}; |
@@ -37,3 +37,3 @@ //(c)2017, MIT Style License <browser-update.org/LICENSE.txt> | ||
for (var i=0; i < pats.length; i++) { | ||
if (ua.match(new RegExp(pats[i][0].replace("VV","(\\d+\\.?\\d?)"),"i"))) { | ||
if (ua.match(new RegExp(pats[i][0].replace("VV","(\\d+\\.?\\d+)"),"i"))) { | ||
n=pats[i][1]; | ||
@@ -43,8 +43,10 @@ break; | ||
} | ||
if (n==="v"||n==="y") {//zero pad semver for easy comparing | ||
var semver=n==="v"||n==="y"; | ||
if (semver) {//zero pad semver for easy comparing | ||
var parts = (RegExp.$1).split('.'); | ||
var v=parseFloat(parts[0] + "." + ("00".substring(0, 2 - parts[1].length) + parts[1])); | ||
var v=(parts[0] + "." + ("00".substring(0, 2 - parts[1].length) + parts[1])); | ||
} | ||
else | ||
var v=parseFloat(RegExp.$1); | ||
else { | ||
var v=Math.round(parseFloat(RegExp.$1)*10)/10; | ||
} | ||
@@ -111,3 +113,3 @@ if (!n) | ||
var vsakt = {i:12,f:53,o:44,s:10.1,n:20,c:58,y:17.04,v:1.10}; | ||
var vsdefault = {i:-2,f:-4,o:-4,s:-1.7,n:12,c:-4,a:534,y:-0.2,v:-0.2}; | ||
var vsdefault = {i:-2,f:-4,o:-4,s:-1.7,n:12,c:-4,a:534,y:-0.02,v:-0.02}; | ||
if (op.apiver<4) | ||
@@ -114,0 +116,0 @@ vsmin={i:9,f:10,o:20,s:7}; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
34703
483