From 6660773ac383e452edebe4cf8484b8d672027898 Mon Sep 17 00:00:00 2001 From: "brindha.venkatesan" Date: Sun, 30 Aug 2020 03:11:20 +0530 Subject: [PATCH] Fix for Issue #161 --- lib/regexps.js | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/lib/regexps.js b/lib/regexps.js index a4cd10d..2a49080 100644 --- a/lib/regexps.js +++ b/lib/regexps.js @@ -1164,7 +1164,7 @@ parser[3] = 0; parser[4] = 0; exports.browser[162] = parser; parser = Object.create(null); -parser[0] = new RegExp("(Chromium|Chrome)/(\\d+)\\.(\\d+)(?:\\.(\\d+)|)(?:\\.(\\d+)|)"); +parser[0] = new RegExp("(Chromium|Chrome)/(\\d+)\\.(\\d+)(?:\\.(\\d+)|)(?:\\.(\\d+)|)(?!.*(?:Edg))"); parser[1] = 0; parser[2] = 0; parser[3] = 0; @@ -1871,7 +1871,7 @@ parser[3] = 0; parser[4] = 0; exports.browser[263] = parser; parser = Object.create(null); -parser[0] = new RegExp("(Safari)/\\d+"); +parser[0] = new RegExp("(Safari)/\\d+(?!.*(?:Edg))"); parser[1] = 0; parser[2] = 0; parser[3] = 0; @@ -2059,8 +2059,15 @@ parser[2] = 0; parser[3] = 0; parser[4] = 0; exports.browser[290] = parser; +parser = Object.create(null); +parser[0] = new RegExp("(Edg)/(\\d+)\\.(\\d+)\\.(\\d+)"); +parser[1] = "Chromium Edge"; +parser[2] = 0; +parser[3] = 0; +parser[4] = 0; +exports.browser[291] = parser; -exports.browser.length = 291; +exports.browser.length = 292; exports.device = Object.create(null);