Skip to content

Commit

Permalink
android Firefox with os version
Browse files Browse the repository at this point in the history
  • Loading branch information
hhatto committed Nov 1, 2021
1 parent 418e1bd commit 98789f6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/woothee/os.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,10 @@ def challenge_smartphone(ua, result):
data = dataset.get('iPod')
elif 'Android' in ua:
data = dataset.get('Android')
regex = re.compile(r"Android[- ](\d+(?:\.\d+(?:\.\d+)?)?)")
m = regex.search(ua)
if m:
os_version = m.group(1)
elif 'CFNetwork' in ua:
data = dataset.get('iOS')
elif 'BB10' in ua:
Expand Down

0 comments on commit 98789f6

Please sign in to comment.