Skip to content

Commit

Permalink
Fix Detection Rule For Amazon Fire TV
Browse files Browse the repository at this point in the history
  • Loading branch information
Junki-Ishida committed Jan 5, 2021
1 parent e4b3029 commit b0f14de
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/ua-parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@
], [MODEL, [VENDOR, 'Amazon'], [TYPE, TABLET]], [
/(sd|kf)[0349hijorstuw]+(\sbuild\/|\)).+silk\//i // Fire Phone
], [[MODEL, mapper.str, maps.device.amazon.model], [VENDOR, 'Amazon'], [TYPE, MOBILE]], [
/android.+aft([bms])\sbuild/i // Fire TV
/android.+aft([\w])(\sbuild\/|\))/i // Fire TV
], [MODEL, [VENDOR, 'Amazon'], [TYPE, SMARTTV]], [

/\((ip[honed|\s\w*]+);.+(apple)/i // iPod/iPhone
Expand Down
9 changes: 9 additions & 0 deletions test/device-test.json
Original file line number Diff line number Diff line change
Expand Up @@ -1219,6 +1219,15 @@
"type": "smarttv"
}
},
{
"desc": "Amazon Fire TV",
"ua": "Mozilla/5.0 (Linux; Android 5.1.1; AFTT) AppleWebKit/537.36 (KHTML, like Gecko) Silk/86.3.20 like Chrome/86.0.4240.198 Safari/537.36",
"expect": {
"vendor": "Amazon",
"model": "T",
"type": "smarttv"
}
},
{
"desc": "Gigaset Tablet",
"ua": "Mozilla/5.0 (Linux; Android 4.2.2; Gigaset QV830 Build/JDQ39) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36",
Expand Down

0 comments on commit b0f14de

Please sign in to comment.