browser-info
Advanced tools
Comparing version 0.2.0 to 0.3.0
@@ -40,2 +40,10 @@ /* globals navigator*/ | ||
} | ||
if (match[1] === 'MSIE') { | ||
tem = /\brv[ :]+(\d+)/g.exec(ua) || []; | ||
return { | ||
name: 'IEMobile', | ||
version: (tem[1]||''), | ||
os: os | ||
}; | ||
} | ||
if (match[1] === 'Chrome') { | ||
@@ -42,0 +50,0 @@ tem = ua.match(/\bOPR\/(\d+)/); |
{ | ||
"name": "browser-info", | ||
"version": "0.2.0", | ||
"version": "0.3.0", | ||
"description": "Get browser info", | ||
@@ -5,0 +5,0 @@ "author": "Steve Lacy <me@slacy.me> (http://slacy.me)", |
@@ -44,2 +44,10 @@ 'use strict'; | ||
it('should detect IE mobile', function(done) { | ||
GLOBAL.navigator = { | ||
userAgent: 'Mozilla/5.0 (compatible; MSIE 9.0; Windows Phone OS 7.5; Trident/5.0; IEMobile/9.0)' | ||
}; | ||
should(info().name).equal('IEMobile'); | ||
done(); | ||
}); | ||
}); |
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
5797
112