@braintree/browser-detection
Advanced tools
Comparing version 1.12.0 to 1.12.1
# Browser Detection - Release Notes | ||
# 1.12.1 (2021-09-28) | ||
- Correct `is-ios-safari` to return `false` for the Facebook browser | ||
# 1.12.0 (2021-06-08) | ||
@@ -4,0 +8,0 @@ |
@@ -8,5 +8,15 @@ "use strict"; | ||
} | ||
function isIosChrome(ua) { | ||
return ua.indexOf("CriOS") > -1; | ||
} | ||
function isFacebook(ua) { | ||
return ua.indexOf("FBAN") > -1; | ||
} | ||
module.exports = function isIosSafari(ua) { | ||
ua = ua || window.navigator.userAgent; | ||
return (isIos(ua) && isWebkit(ua) && ua.indexOf("CriOS") === -1 && !isIosFirefox(ua)); | ||
return (isIos(ua) && | ||
isWebkit(ua) && | ||
!isIosChrome(ua) && | ||
!isIosFirefox(ua) && | ||
!isFacebook(ua)); | ||
}; |
{ | ||
"name": "@braintree/browser-detection", | ||
"version": "1.12.0", | ||
"version": "1.12.1", | ||
"description": "A small lib to detect browser compatibility for braintree products", | ||
@@ -13,10 +13,10 @@ "main": "dist/browser-detection.js", | ||
"devDependencies": { | ||
"@types/jest": "^26.0.23", | ||
"@types/node": "^15.6.1", | ||
"eslint": "^7.27.0", | ||
"@types/jest": "^27.0.2", | ||
"@types/node": "^16.9.6", | ||
"eslint": "^7.32.0", | ||
"eslint-config-braintree": "^5.0.0-typescript-prep-rc.18", | ||
"jest": "^27.0.3", | ||
"prettier": "^2.3.0", | ||
"ts-jest": "^27.0.2", | ||
"typescript": "^4.3.2" | ||
"jest": "^27.2.1", | ||
"prettier": "^2.4.1", | ||
"ts-jest": "^27.0.5", | ||
"typescript": "^4.4.3" | ||
}, | ||
@@ -23,0 +23,0 @@ "scripts": { |
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
21235
382