From 0001859ba86d56518e0e32fac822819645950014 Mon Sep 17 00:00:00 2001 From: rolux Date: Sat, 27 Oct 2012 21:59:40 +0200 Subject: [PATCH] improve parse_useragent --- ox/text.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ox/text.py b/ox/text.py index 636d9ad..d380bdb 100644 --- a/ox/text.py +++ b/ox/text.py @@ -57,6 +57,7 @@ UA_NAMES = { 'chromeframe': 'Chrome Frame', 'FBForIPhone': 'WebKit', 'Gecko': 'Mozilla', + 'konqueror': 'Konqueror', 'Mozilla': 'Netscape', 'MSIE': 'Internet Explorer', 'NokiaBrowser': 'Nokia Browser' @@ -82,14 +83,15 @@ UA_REGEXPS = { '(Camino)\/(\d+)', '(Chimera)\/(\d+)', '(chromeframe)\/(\d+)', - '(Chromium)\/(\d+)', + '(Epiphany)\/(\d+)', # before Chrome, Chromium and Safari + '(Chromium)\/(\d+)', # before Chrome '(Chrome)\/(\d+)', - '(Epiphany)\/(\d+)', '(FBForIPhone)', '(Firefox)\/(\d+)', '(Galeon)\/(\d+)', '(iCab) (\d+)', '(iCab)\/(\d+)', + '(konqueror)\/(\d+)', '(Konqueror)\/(\d+)', '(Lynx)\/(\d+)', '(Netscape)\d?\/(\d+)',